mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-07-08 18:06:30 +00:00
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/CCExtractor/ccextractor/pull/1878
Author: @cfsmp3
Created: 12/21/2025
Status: ✅ Merged
Merged: 12/22/2025
Merged by: @cfsmp3
Base:
master← Head:fix/issue-1010-ocr-null-bitmap-crash📝 Commits (1)
3304c1bfix(ocr): Handle NULL bitmap gracefully instead of crashing (#1010)📊 Changes
1 file changed (+41 additions, -17 deletions)
View changed files
📝
src/lib_ccx/ocr.c(+41 -17)📄 Description
Summary
Root Cause
The code path was:
pixClipRectanglefails → "box outside rectangle" errorpixConvertRGBToGrayreceives NULL → "pixs not defined" errorcpix_gsis NULL, but code continues to line 415TessBaseAPIGetUTF8Textreturns NULL (no image was set)fatal()is called → crashFix
cpix_gs == NULLby cleaning up and returning NULL (skip bitmap)TessBaseAPIGetUTF8TextNULL case from fatal error to graceful skipTesting
This fix allows CCExtractor to continue processing even when individual subtitle frames are corrupted, which is critical for live streams where packet loss can occur.
Fixes #1010
🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.