[Poppler-bugs] [Bug 107057] [Patch] Skip XRef gaps in PDFDoc save methods

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Jul 5 16:14:22 UTC 2018


https://bugs.freedesktop.org/show_bug.cgi?id=107057

--- Comment #10 from Tobias Deiminger <haxtibal at posteo.de> ---
(In reply to Albert Astals Cid from comment #9)
> No, on save you always use DoNotTryToRecoverIfNone, it's what you're doing
> with your patch code, no?

Yes, that's perfectly fine, the code in saveXXX can always look like
xref->getEntry(i, DoNotTryToRecoverIfNone).

I meant this: If we have a different problem besides "none" during saveXXX (say
"offset mismatch"), we actually do want to start recovery, is it? That's how
the current patch behaves. The getEntry API is not explicit about other error
scenarios. The enum for example contains no DoNotTryToRecoverIfWrongOffset. My
comment was about if this is consistent and understandable for other
programmers. My own answer would be "no" to consistent, and "yes" to
understandable.

I'm currently working on grasping XRef::readXRefUntil, only then I can provide
an updated patch.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/poppler-bugs/attachments/20180705/38f34d13/attachment.html>


More information about the Poppler-bugs mailing list