Hi Till,
> when using XEP 4.23 to create a PDF file with an additional PDF attachment, there is a
> NullPointerException and the resulting PDF cannot be read.
>
It's a 'a1_attachment-1-page-3.pdf' that cause the NPE.
This PDF file is a TOC and contains links.
Each link itself is an annotations with a GoTo action (in terms of PDF Specification).
In more simple words: you click on the link and will be forwarded to some place on other page.
A PDF splitting software (iText in your case) correctly removes all objects from other pages, but keeps the
"hanging" links.
By "hanging" I mean an indirect PDF object reference without the PDF object itself.
For example,
<</D[20 0 R/XYZ 52 715 0.0]/S/GoTo>>
where 20 0 R is the indirect reference to another page, but the obj #20 (20 0 R) itself is absent in the
PDF file.
In such a case XEP fails to create a PDF image.
And, in my opinion, it's the most reasonable behavior -- no PDF image when parsing of the PDF is failed.
Not with NPE, of course :) -- it's our fault, I will fix.
I believe it's worth to ping iText about removing "hanging" indirect objects for links (PDF Annots) during
splitting a PDF file.
--- With best regards, Alexey Gagarinov RenderX
_______________________________________________
(*) To unsubscribe, please visit http://lists.renderx.com/mailman/options/xep-support
(*) By using the Service, you expressly agree to these Terms of Service http://w
ww.renderx.com/terms-of-service.html
Received on Fri Sep 1 17:46:48 2017
This archive was generated by hypermail 2.1.8 : Fri Sep 01 2017 - 17:47:00 PDT