gs: work arround broken xref table pdfs
rebuilding the xref table does not work for pdfs with compressed object streams. as a work arround, we skip xref table verification and ignore wrong xref gen # for gen 0 objects.
This commit is contained in:
parent
581f3852fe
commit
13508a99a8
2 changed files with 5 additions and 4 deletions
|
@ -412,11 +412,10 @@ pdfdict begin
|
||||||
( **** Warning: wrong generation: )
|
( **** Warning: wrong generation: )
|
||||||
} ifelse
|
} ifelse
|
||||||
2 index =string cvs concatstrings ( ) concatstrings % put obj #
|
2 index =string cvs concatstrings ( ) concatstrings % put obj #
|
||||||
exch =string cvs concatstrings ( R\n) concatstrings % put gen #
|
1 index =string cvs concatstrings ( R\n) concatstrings % put gen #
|
||||||
pdfformaterror % Output warning message
|
pdfformaterror % Output warning message
|
||||||
} { % Else QUIET ...
|
} if
|
||||||
pop % Pop generation umber
|
0 eq
|
||||||
} ifelse false % Return false if gen # not match
|
|
||||||
} ifelse
|
} ifelse
|
||||||
} bind def
|
} bind def
|
||||||
/R { % <object#> <generation#> R <object>
|
/R { % <object#> <generation#> R <object>
|
||||||
|
|
|
@ -25,6 +25,8 @@ pdfdict begin
|
||||||
% Patch in an obsolete variable used by some third-party software.
|
% Patch in an obsolete variable used by some third-party software.
|
||||||
/#? false def
|
/#? false def
|
||||||
|
|
||||||
|
/NoVerifyXref true def
|
||||||
|
|
||||||
% Test whether the current output device handles pdfmark.
|
% Test whether the current output device handles pdfmark.
|
||||||
/.writepdfmarkdict 1 dict dup /pdfmark null put readonly def
|
/.writepdfmarkdict 1 dict dup /pdfmark null put readonly def
|
||||||
/.writepdfmarks { % - .writepdfmarks <bool>
|
/.writepdfmarks { % - .writepdfmarks <bool>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue