You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently seeing a SIGBUS crash in ComputeGradient on an Android app I'm working on, I can reliably reproduce the crash on a specific phone (Samsung Galaxy S4 Mini, Snapdragon 400), on another device (OnePlus One, Snapdragon 801)
Backtrace (app name removed):
D/CrashAnrDetector( 656): backtrace:
D/CrashAnrDetector( 656): #00 pc 000a746c /data/app-lib/APPNAME/libtess.so
D/CrashAnrDetector( 656): #1 pc 000a8935 /data/app-lib/APPNAME/libtess.so (C_OUTLINE::ComputeEdgeOffsets(int, Pix_)+160)
D/CrashAnrDetector( 656): #2 pc 000b81b1 /data/app-lib/APPNAME/libtess.so
D/CrashAnrDetector( 656): #3 pc 000a3a1d /data/app-lib/APPNAME/libtess.so (BLOBNBOX::ComputeEdgeOffsets(Pix_, Pix_, BLOBNBOX_LIST_)+212)
D/CrashAnrDetector( 656): #4 pc 000a42b7 /data/app-lib/APPNAME/libtess.so (TO_BLOCK::ComputeEdgeOffsets(Pix_, Pix_)+14)
D/CrashAnrDetector( 656): #5 pc 0011f099 /data/app-lib/APPNAME/libtess.so (tesseract::Textord::TextordPage(tesseract::PageSegMode, FCOORD const&, int, int, Pix_, Pix_, Pix_, bool, BLOBNBOX_LIST_, BLOCK_LIST_, TO_BLOCK_LIST_)+72)
I added some debug output to ComputeGradient and it turns out it crashes when y = -2. , after adding a few more lines of debug logging in ComputeEdgeOffsets I see that start.y() is 2 larger than 'height'. If it crashes, it always does so on line 2 of ComputeGradient. SIGBUS would imply an unaligned memory access but as far as I can tell that function only deals with single byte access which shouldn't cause an issue. The -2 y coordinate also seems suspect but I don't know enough about Tesseract and Pix to know if that might be a problem or not.
The text was updated successfully, but these errors were encountered:
Please see FAQ: If you found a bug - please create an issue: Please make sure you are able to replicate the problem with tesseract executables on Linux or Windows. For other platforms or external/your programs (including tesseract wrappers) please use the tesseract forums.
I'm currently seeing a SIGBUS crash in ComputeGradient on an Android app I'm working on, I can reliably reproduce the crash on a specific phone (Samsung Galaxy S4 Mini, Snapdragon 400), on another device (OnePlus One, Snapdragon 801)
Backtrace (app name removed):
D/CrashAnrDetector( 656): backtrace:
D/CrashAnrDetector( 656): #00 pc 000a746c /data/app-lib/APPNAME/libtess.so
D/CrashAnrDetector( 656): #1 pc 000a8935 /data/app-lib/APPNAME/libtess.so (C_OUTLINE::ComputeEdgeOffsets(int, Pix_)+160)
D/CrashAnrDetector( 656): #2 pc 000b81b1 /data/app-lib/APPNAME/libtess.so
D/CrashAnrDetector( 656): #3 pc 000a3a1d /data/app-lib/APPNAME/libtess.so (BLOBNBOX::ComputeEdgeOffsets(Pix_, Pix_, BLOBNBOX_LIST_)+212)
D/CrashAnrDetector( 656): #4 pc 000a42b7 /data/app-lib/APPNAME/libtess.so (TO_BLOCK::ComputeEdgeOffsets(Pix_, Pix_)+14)
D/CrashAnrDetector( 656): #5 pc 0011f099 /data/app-lib/APPNAME/libtess.so (tesseract::Textord::TextordPage(tesseract::PageSegMode, FCOORD const&, int, int, Pix_, Pix_, Pix_, bool, BLOBNBOX_LIST_, BLOCK_LIST_, TO_BLOCK_LIST_)+72)
I added some debug output to ComputeGradient and it turns out it crashes when y = -2. , after adding a few more lines of debug logging in ComputeEdgeOffsets I see that start.y() is 2 larger than 'height'. If it crashes, it always does so on line 2 of ComputeGradient. SIGBUS would imply an unaligned memory access but as far as I can tell that function only deals with single byte access which shouldn't cause an issue. The -2 y coordinate also seems suspect but I don't know enough about Tesseract and Pix to know if that might be a problem or not.
The text was updated successfully, but these errors were encountered: