[poppler] Branch 'poppler-0.20' - poppler/XRef.cc
Albert Astals Cid
aacid at kemper.freedesktop.org
Tue Oct 16 15:22:20 PDT 2012
poppler/XRef.cc | 1 +
1 file changed, 1 insertion(+)
New commits:
commit 528b64bb077ed37c0d8fc7ae2ef3dc2c0dbb26ca
Author: Fabio D'Urso <fabiodurso at hotmail.it>
Date: Tue Sep 4 23:10:17 2012 +0200
Free entries in the xref form a linked list: terminate it properly when writing the XRef
The last entry must point back to object 0. Previously it was left
unitialized and resulted in "-000000001 00000 f" being written in the
XRef table.
diff --git a/poppler/XRef.cc b/poppler/XRef.cc
index a076bb0..b516a0f 100644
--- a/poppler/XRef.cc
+++ b/poppler/XRef.cc
@@ -1269,6 +1269,7 @@ void XRef::writeXRef(XRef::XRefWriter *writer, GBool writeAllEntries) {
lastFreeEntry = i;
}
}
+ getEntry(lastFreeEntry)->offset = 0;
if (writeAllEntries) {
writer->startSection(0, size);
More information about the poppler
mailing list