mirror of
https://github.com/ocrmypdf/OCRmyPDF.git
synced 2026-05-06 21:56:21 -04:00
weave: clarify comment about garbage data in ToC
This commit is contained in:
@@ -169,10 +169,8 @@ def _traverse_toc(pdf_base, visitor_fn, log):
|
||||
continue
|
||||
item = node[key]
|
||||
if not item.is_indirect:
|
||||
# or not isinstance(item, pikepdf.Dictionary):
|
||||
# # If there is garbage data, replace the key with an indirect
|
||||
# # ref to None. Kodak Capture Desktop produces keys like these.
|
||||
# log.error('Removing invalid reference from TOC: %s', repr(item))
|
||||
# Direct references are not allowed here, but it's not clear
|
||||
# what we should do if we find any. Removing them is an option:
|
||||
# node[key] = pdf_base.make_indirect(None)
|
||||
continue
|
||||
objgen = item.objgen
|
||||
|
||||
Reference in New Issue
Block a user