Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore invalid '/Prev 0' in trailer #383

Merged
merged 1 commit into from Nov 7, 2021
Merged

Ignore invalid '/Prev 0' in trailer #383

merged 1 commit into from Nov 7, 2021

Conversation

sebbASF
Copy link
Contributor

@sebbASF sebbASF commented Oct 28, 2021

I've seen this bug in a couple of PDFs which just contain an image.
The various viewers I have tried seem to just ignore it.

No Creator entry, so don't know what app does this...

@yob
Copy link
Owner

yob commented Nov 6, 2021

Cheers, if other readers handle this issue then it'd be great for pdf-reader to as well.

Do you think we can get a spec in spec/integration_spec.rb for a file with this issue?

A trick/hack I often use is to generate a file with prawn, but modify my local copy of the pdf-core gem to tweak the way the PDF is serialised to disk. That might be an easy-ish way to add in a garbage /Prev 0 entry.

@yob yob merged commit d0f3296 into yob:main Nov 7, 2021
@sebbASF sebbASF deleted the prev-zero branch November 7, 2021 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants