File poppler-setFlag-invalid-read.patch of Package poppler.31330
Index: poppler-0.62.0/poppler/Parser.cc
===================================================================
--- poppler-0.62.0.orig/poppler/Parser.cc
+++ poppler-0.62.0/poppler/Parser.cc
@@ -291,8 +292,15 @@ Stream *Parser::makeStream(Object &&dict
// get filters
str = str->addFilters(str->getDict(), recursion);
- if (entry)
- entry->setFlag(XRefEntry::Parsing, false);
+ if (entry) {
+ // Don't try to reuse the entry from the block at the start
+ // of the function, xref can change in the middle because of
+ // reconstruction
+ XRefEntry *e = xref->getEntry(objNum, false);
+ if (e) {
+ e->setFlag(XRefEntry::Parsing, false);
+ }
+ }
return str;
}