Skip to content
Permalink
Browse files Browse the repository at this point in the history
fixed #2175
  • Loading branch information
jeanlf committed Apr 19, 2022
1 parent 1773b7a commit 3dbe11b
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions src/isomedia/box_code_3gpp.c
Expand Up @@ -1128,20 +1128,12 @@ void diST_box_del(GF_Box *s)

GF_Err diST_box_read(GF_Box *s, GF_BitStream *bs)
{
u32 i;
char str[1024];
GF_DIMSScriptTypesBox *p = (GF_DIMSScriptTypesBox *)s;

i=0;
str[0]=0;
while (1) {
str[i] = gf_bs_read_u8(bs);
if (!str[i]) break;
i++;
}
ISOM_DECREASE_SIZE(p, i);

p->content_script_types = gf_strdup(str);
p->content_script_types = gf_malloc(sizeof(char) * (s->size+1));
if (!p->content_script_types) return GF_OUT_OF_MEM;
gf_bs_read_data(bs, p->content_script_types, s->size);
p->content_script_types[s->size] = 0;
return GF_OK;
}

Expand Down

0 comments on commit 3dbe11b

Please sign in to comment.