Remove safety traversal of PDF table of contents

qpdf fixed the danging reference issue (qpdf #240) in 8.3.0, which is
required by pikepdf 1.1.0. We no
longer need the workaround.
This commit is contained in:
James R. Barlow
2019-04-13 00:24:03 -07:00
parent 6e49bb3588
commit 922a107b7f
-6
View File
@@ -322,12 +322,6 @@ def weave_layers(infiles, output_file, log, context):
pdfinfo = context.get_pdfinfo()
pagerefs = {}
# Walk the table of contents first, to trigger pikepdf/qpdf to resolve all
# page references in the table of contents. Some PDF generators put invalid
# references in the ToC, so we want to resolve them to null before we
# create any references, or the ToC will be corrupted
_traverse_toc(pdf_base, None, log)
procset = pdf_base.make_indirect(
pikepdf.Object.parse(b'[ /PDF /Text /ImageB /ImageC /ImageI ]')
)