Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1553235

Summary: pdftocairo doesn't work as expected
Product: Red Hat Enterprise Linux 7 Reporter: jigar <jraising>
Component: openjpegAssignee: Nikola Forró <nforro>
Status: CLOSED ERRATA QA Contact: Maryna Nalbandian <mnalband>
Severity: medium Docs Contact: Marie Hornickova <mdolezel>
Priority: unspecified    
Version: 7.4CC: ayadav, crungeho, jkejda, nforro, ovasik, tpelka
Target Milestone: rcKeywords: Patch
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: openjpeg-1.5.1-18.el7 Doc Type: Release Note
Doc Text:
Decoding and conversion of JPEG 2000 images now work correctly Previously, decoding and conversion of JPEG 2000 images did not work correctly due to a bug in the `openjpeg` library. With this update, the underlying source code has been fixed, and decoding and conversion of JPEG 2000 images now works as expected.
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-10-30 10:13:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
test file
none
Backported patch from upstream none

Description jigar 2018-03-08 14:52:12 UTC
Created attachment 1405882 [details]
test file

Description of problem: When trying to convert pdf to image ( jpeg ), pdftocairo fails to convert it successfully. 

Version-Release number of selected component (if applicable): poppler-0.26.5-17.el7_4

How reproducible: Always ( with given test file )

Steps to Reproduce:
1. Download the test file
2. Convert it from pdf to image format using the following command :

$ pdftocairo -jpeg -cropbox -r 360 -scale-to 2401 -x 0 -y 0 -W 2400 -H 2400 <input_file> <output_file>

3. Following errors/messages are seen while conversion in RHEL 7 :

Syntax Error: tcd_decode: incomplete bistream<0a>
Syntax Error: Error in decoding tile<0a>
Syntax Error: Failed to decode J2K image<0a>
Syntax Warning: Did no succeed opening JPX Stream as JP2, trying as J2K.
Syntax Error: 00000000: expected a marker instead of 0<0a>
Syntax Warning: Did no succeed opening JPX Stream as J2K, trying as JPT.
Syntax Error: Forbidden value encounter in message header !!<0a>
Syntax Error: [JPT-stream] : Expecting Main header first [class_Id 0] !<0a>
Syntax Error: Did no succeed opening JPX Stream.

4. Check the output file

Actual results: pdftocairo fails to convert as pdf to images successfully

Expected results: pdftocairo should convert as expected

Comment 3 Marek Kašík 2018-03-26 13:42:04 UTC
This is an issue in openjpeg package. I'm able to reproduce the same errors when running "j2k_to_image" on the extracted image.

Steps:
1) pdfimages -f 1 -l 1 -jp2 test.pdf image
2) copy the result to image.jp2, image.j2k and image.jpt
3) j2k_to_image -i image.jp2 -o image.pgm
4) j2k_to_image -i image.j2k -o image.pgm
5) j2k_to_image -i image.jpt -o image.pgm

I'm reassigning this to openjpeg.

Comment 5 Nikola Forró 2018-04-05 16:06:45 UTC
Created attachment 1417839 [details]
Backported patch from upstream

Comment 16 errata-xmlrpc 2018-10-30 10:13:22 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:3125