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

Index out of bouds #9

Open
GBriotti opened this issue Nov 2, 2021 · 2 comments
Open

Index out of bouds #9

GBriotti opened this issue Nov 2, 2021 · 2 comments

Comments

@GBriotti
Copy link

GBriotti commented Nov 2, 2021

Just received this, parsing a PDF:

Index out of bounds.
Generated exception: 'System.IndexOutOfRangeException' in JBig2Decoder.dll

I'm investigating more in deep...

@GBriotti
Copy link
Author

GBriotti commented Nov 2, 2021

OK. It seems related to JBig2Image.cs. The method readbitmap() has this snippet of code:

if (typicalPredictionGenericDecodingOn) { int bit = arithmeticDecoder.DecodeBit(ltpCX, arithmeticDecoder.genericRegionStats); if (bit != 0) { ltp = !ltp; } if (ltp) { DuplicateRow(row, row - 1); continue; } }

where ltp is true and row is zero... thus duplicaterow fails...

@GBriotti
Copy link
Author

GBriotti commented Nov 2, 2021

Well, it seems that is the same issue resolved by the pull request Update JBig2Image.cs

Applying the corrections it works for me!

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

No branches or pull requests

1 participant