File tree 1 file changed +4
-2
lines changed
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -282,7 +282,8 @@ GF_Err iloc_box_read(GF_Box *s, GF_BitStream *bs)
282282 }
283283
284284 for (i = 0 ; i < item_count ; i ++ ) {
285- GF_ItemLocationEntry * location_entry = (GF_ItemLocationEntry * )gf_malloc (sizeof (GF_ItemLocationEntry ));
285+ GF_ItemLocationEntry * location_entry ;
286+ GF_SAFEALLOC (location_entry , GF_ItemLocationEntry );
286287 if (!location_entry ) return GF_OUT_OF_MEM ;
287288
288289 gf_list_add (ptr -> location_entries , location_entry );
@@ -311,7 +312,8 @@ GF_Err iloc_box_read(GF_Box *s, GF_BitStream *bs)
311312 extent_count = gf_bs_read_u16 (bs );
312313 location_entry -> extent_entries = gf_list_new ();
313314 for (j = 0 ; j < extent_count ; j ++ ) {
314- GF_ItemExtentEntry * extent_entry = (GF_ItemExtentEntry * )gf_malloc (sizeof (GF_ItemExtentEntry ));
315+ GF_ItemExtentEntry * extent_entry ;
316+ GF_SAFEALLOC (extent_entry , GF_ItemExtentEntry );
315317 if (!extent_entry ) return GF_OUT_OF_MEM ;
316318
317319 gf_list_add (location_entry -> extent_entries , extent_entry );
You can’t perform that action at this time.
0 commit comments