Skip to content

Commit 2ec93c3

Browse files
cfsmp3claude
andcommitted
fix(rust): Check dtvcc_rust instead of dtvcc in ccxr_process_cc_data
When Rust CEA-708 decoder is enabled, dec_ctx.dtvcc is set to NULL and dec_ctx.dtvcc_rust holds the actual DtvccRust context. The null check was incorrectly checking dtvcc, causing the function to return early and skip all CEA-708 data processing. This fixes tests 21, 31, 32, 105, 137, 141-149 which were failing with exit code 10 (EXIT_NO_CAPTIONS) because no captions were being extracted from CEA-708 streams. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent ead4cbb commit 2ec93c3

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/rust/src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -392,8 +392,9 @@ extern "C" fn ccxr_process_cc_data(
392392

393393
let dec_ctx = unsafe { &mut *dec_ctx };
394394

395-
// Check dtvcc pointer before dereferencing
396-
if dec_ctx.dtvcc.is_null() {
395+
// Check dtvcc_rust pointer before dereferencing (not dtvcc!)
396+
// When Rust is enabled, dtvcc is NULL and dtvcc_rust holds the actual context
397+
if dec_ctx.dtvcc_rust.is_null() {
397398
return -1;
398399
}
399400

0 commit comments

Comments
 (0)