[ 
https://issues.apache.org/jira/browse/PDFBOX-5226?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17370222#comment-17370222
 ] 

Andreas Lehmkühler edited comment on PDFBOX-5226 at 6/27/21, 2:05 PM:
----------------------------------------------------------------------

The dictionary {{843 0 R}} contains the object reference {{844 0}} which can't 
be dereferenced as the object isn't part of the pdf. 
{code}
843 0 obj
<<
/Type /Annot
/Subtype /Widget
/Rect [54.31305 356.2674 297.76331 370.32489]
/F 4
/P 844 0 R
/DA (/Arial 0 Tf 0 g)
/Parent 410 0 R
/AP <<
/N 845 0 R
>>
{code}
Those references are omitted when it comes to compressed object streams which 
led to an invalid dictionary as the key is written but the value isn't. I've 
fixed that so that the behaviour is identical for compressed and uncompressed 
pdfs. In both cases the reference is written nevertheless it can't be 
dereferenced at all.



was (Author: lehmi):
The dictionary 843 0 R contains the object reference 844 0 which can't be 
dereferenced as the object isn't part of the pdf. Those references are omitted 
when it comes to compressed object streams which led to an invalid dictionary 
as the key is written but the value isn't. I've fixed that so that the 
behaviour is identical for compressed and uncompressed pdfs. In both cases the 
reference is written nevertheless it can't be dereferenced at all.

> File saved with PDFBox can't be opened with Adobe Reader
> --------------------------------------------------------
>
>                 Key: PDFBOX-5226
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-5226
>             Project: PDFBox
>          Issue Type: Bug
>          Components: Writing
>    Affects Versions: 3.0.0 PDFBox
>            Reporter: Tilman Hausherr
>            Assignee: Andreas Lehmkühler
>            Priority: Major
>             Fix For: 3.0.0 PDFBox
>
>         Attachments: SourceFailure-saved3.pdf, SourceFailure.pdf
>
>
> Loading and saving the file from PDFBOX-5225 creates a file that can't be 
> opened with Adobe Reader, and also parsing errors when opening with PDFBox. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to