Skip to content

Commit c58f053

Browse files
committed
fixed an issue within PAT table parsing data verification
1 parent 861e910 commit c58f053

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/tsdemux.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,7 @@ TSDCode tsd_parse_table(TSDemuxContext *ctx,
431431
ptr += section_len + 3;
432432
section_count++;
433433

434-
if((ptr+1) < dataCtx->write && (*(ptr+1) == 0xFF) || (0x00 == *(ptr+1))) {
434+
if((ptr <= dataCtx->write) && ((*(ptr+1) == 0xFF) || (0x00 == *(ptr+1)))) {
435435
// create and parse the sections.
436436
table->length = section_count;
437437
table->sections = (TSDTableSection*) ctx->calloc(section_count,

0 commit comments

Comments
 (0)