Skip to content

Commit 98b38f9

Browse files
authored
Merge pull request #121 from yilun-zhangs/main
fix one possible crash when decoding iamf bitstream file
2 parents caeae33 + d70de50 commit 98b38f9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

code/src/iamf_dec/IAMF_decoder.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2964,7 +2964,7 @@ static int iamf_decoder_internal_init(IAMF_DecoderHandle handle,
29642964
IAMF_OBU obj;
29652965
ia_logi("Without magic code flag.");
29662966
while (pos < size) {
2967-
consume = IAMF_OBU_split(data, size, &obj);
2967+
consume = IAMF_OBU_split(data + pos, size - pos, &obj);
29682968
if (!consume || obj.type == IAMF_OBU_SEQUENCE_HEADER) {
29692969
ia_logi("Get magic code.");
29702970
break;

0 commit comments

Comments
 (0)