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

PDF rendering fails with: bad XRef entry #2388

Closed
ghost opened this issue Nov 15, 2012 · 8 comments
Closed

PDF rendering fails with: bad XRef entry #2388

ghost opened this issue Nov 15, 2012 · 8 comments

Comments

@ghost
Copy link

ghost commented Nov 15, 2012

Hi,

I am using the latest build of PDF JS. The PDF which can be found at this link fails to render with error: "bad XRef entry" .:

https://docs.google.com/open?id=0B0ssZE2muxClTkRuamdCSkZ0Zmc

This PDF contains an image taken from Bing Maps.

@ghost
Copy link
Author

ghost commented Nov 20, 2012

Hi did you get a chance to look at this issue? Our dev team is waiting for this to get fixed so that we can integrated PDF JS in our mobile app.

@saebekassebil
Copy link
Contributor

@nishanthnair: Since this is tagged '3-pdf-broken', it means that this PDF doesn't follow the PDF standard that PDF.js supports. It's also tagged '4-triage-needed', which means that the core team will discuss this issue at an upcoming triage meeting. There was a meeting yesterday, and the next will be held on Monday, 3. Dec. Try peeking in at #pdfjs @ irc.mozilla.org maybe some of the core developers can answer you what the problem is.

@ghost
Copy link
Author

ghost commented Nov 20, 2012

@saebekassebil Thanks a lot for the reply. I was not aware of the meaning of these tags. Will eagerly wait for a fix from the PDF.JS team as PDF.JS a great solution to display PDF on hybrid mobile apps.

Thanks,
Nishanth

@ghost
Copy link
Author

ghost commented Nov 21, 2012

update: I tried to open this PDF with PDF Viewer firefox plugin and it opened without any issue. But using PDF.js JS API, error appears.

@yurydelendik
Copy link
Contributor

Looks like this pdf is corrupted -- the file has obj 41 0 and obj 42 0 entries pointed to the same location. When 41 is requested, the stored object informs it has num == 42. Therefore error message at https://github.com/mozilla/pdf.js/blob/master/src/obj.js#L673

@ghost
Copy link
Author

ghost commented Nov 27, 2012

@yurydelendik Thanks for looking in to this issue. This PDF is generated by Telerik Reporting API and can be opened using any PDF reader other than PDF.JS. So is this something that can be fixed from PDF.JS side?

@brendandahl
Copy link
Contributor

Fixed by above PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants
@saebekassebil @brendandahl @yurydelendik and others