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

Fix out of bounds array access #3045

Merged
merged 1 commit into from
Jun 29, 2020
Merged

Fix out of bounds array access #3045

merged 1 commit into from
Jun 29, 2020

Conversation

stweil
Copy link
Contributor

@stweil stweil commented Jun 29, 2020

Runtime error with enabled sanitizer:

src/textord/colpartition.cpp:2243:66: runtime error: index -1 out of bounds for type 'tesseract::ColPartition *[6]'
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/textord/colpartition.cpp:2243:66 in 

Signed-off-by: Stefan Weil sw@weilnetz.de

Runtime error with enabled sanitizer:

    src/textord/colpartition.cpp:2243:66: runtime error: index -1 out of bounds for type 'tesseract::ColPartition *[6]'
    SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/textord/colpartition.cpp:2243:66 in

Signed-off-by: Stefan Weil <sw@weilnetz.de>
@stweil stweil merged commit 7c046c1 into tesseract-ocr:master Jun 29, 2020
@stweil stweil deleted the fix branch June 29, 2020 14:10
@amitdo
Copy link
Collaborator

amitdo commented Jun 30, 2020

Was this triggered by one of the unit tests?

@stweil
Copy link
Contributor Author

stweil commented Jun 30, 2020

All recently fixed sanitizer issues were found with the image from #3021 (comment) by running tesseract 0046.png -. I did not test whether the unit test also triggered those issues.

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.

2 participants