diff options
author | Simon Bünzli <zeniko@gmail.com> | 2015-01-04 23:38:09 +0100 |
---|---|---|
committer | Simon Bünzli <zeniko@gmail.com> | 2015-01-20 20:55:56 +0100 |
commit | 671c29011618e091845e83e23eb2e6a700e10906 (patch) | |
tree | 190fe86380a0514f1930368c9e1be6b0a5784703 /source/pdf | |
parent | 036a6270c67e28e63f826edc1c0958403edaf783 (diff) | |
download | mupdf-671c29011618e091845e83e23eb2e6a700e10906.tar.xz |
Bug 695770: fix TODO in commit d7c0c0856b31be17823ae4745b2c542a9c71765f
pdf_xref_find_subsection does indeed solidify the wrong xref section:
it should operate only on the oldest xref and not overwrite the most
recent one with older entries.
Diffstat (limited to 'source/pdf')
-rw-r--r-- | source/pdf/pdf-xref.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/pdf/pdf-xref.c b/source/pdf/pdf-xref.c index c99f8350..549809a2 100644 --- a/source/pdf/pdf-xref.c +++ b/source/pdf/pdf-xref.c @@ -658,8 +658,8 @@ pdf_xref_find_subsection(pdf_document *doc, int ofs, int len) else { /* Case 3 */ - ensure_solid_xref(doc, new_max, 0); - xref = &doc->xref_sections[0]; + ensure_solid_xref(doc, new_max, doc->num_xref_sections-1); + xref = &doc->xref_sections[doc->num_xref_sections-1]; sub = xref->subsec; } return &sub->table[ofs-sub->start]; |