Commit c99c90d1 authored by Francois Cartegnie's avatar Francois Cartegnie

demux: mp4: rename union data pointer.

Avoid naming confusion, because data is an atom itself.
parent b8f8588e
...@@ -90,7 +90,7 @@ int MP4_ReadBoxCommon( stream_t *p_stream, MP4_Box_t *p_box ) ...@@ -90,7 +90,7 @@ int MP4_ReadBoxCommon( stream_t *p_stream, MP4_Box_t *p_box )
} }
p_box->i_pos = stream_Tell( p_stream ); p_box->i_pos = stream_Tell( p_stream );
p_box->data.p_data = NULL; p_box->data.p_payload = NULL;
p_box->p_father = NULL; p_box->p_father = NULL;
p_box->p_first = NULL; p_box->p_first = NULL;
p_box->p_last = NULL; p_box->p_last = NULL;
...@@ -3467,7 +3467,7 @@ void MP4_BoxFree( stream_t *s, MP4_Box_t *p_box ) ...@@ -3467,7 +3467,7 @@ void MP4_BoxFree( stream_t *s, MP4_Box_t *p_box )
} }
/* Now search function to call */ /* Now search function to call */
if( p_box->data.p_data ) if( p_box->data.p_payload )
{ {
for( i_index = 0; ; i_index++ ) for( i_index = 0; ; i_index++ )
{ {
...@@ -3493,7 +3493,7 @@ void MP4_BoxFree( stream_t *s, MP4_Box_t *p_box ) ...@@ -3493,7 +3493,7 @@ void MP4_BoxFree( stream_t *s, MP4_Box_t *p_box )
{ {
MP4_Box_Function[i_index].MP4_FreeBox_function( p_box ); MP4_Box_Function[i_index].MP4_FreeBox_function( p_box );
} }
free( p_box->data.p_data ); free( p_box->data.p_payload );
} }
free( p_box ); free( p_box );
} }
...@@ -3591,7 +3591,7 @@ MP4_Box_t *MP4_BoxGetRoot( stream_t *s ) ...@@ -3591,7 +3591,7 @@ MP4_Box_t *MP4_BoxGetRoot( stream_t *s )
p_root->i_size = 0; p_root->i_size = 0;
CreateUUID( &p_root->i_uuid, p_root->i_type ); CreateUUID( &p_root->i_uuid, p_root->i_type );
p_root->data.p_data = NULL; p_root->data.p_payload = NULL;
p_root->p_father = NULL; p_root->p_father = NULL;
p_root->p_first = NULL; p_root->p_first = NULL;
p_root->p_last = NULL; p_root->p_last = NULL;
......
...@@ -1250,7 +1250,7 @@ typedef union MP4_Box_data_s ...@@ -1250,7 +1250,7 @@ typedef union MP4_Box_data_s
MP4_Box_data_tfxd_t *p_tfxd; MP4_Box_data_tfxd_t *p_tfxd;
MP4_Box_data_hvcC_t *p_hvcC; MP4_Box_data_hvcC_t *p_hvcC;
void *p_data; /* for unknow type */ void *p_payload; /* for unknow type */
} MP4_Box_data_t; } MP4_Box_data_t;
...@@ -1431,7 +1431,7 @@ static inline size_t mp4_box_headersize( MP4_Box_t *p_box ) ...@@ -1431,7 +1431,7 @@ static inline size_t mp4_box_headersize( MP4_Box_t *p_box )
} \ } \
p_peek += mp4_box_headersize( p_box ); \ p_peek += mp4_box_headersize( p_box ); \
i_read -= mp4_box_headersize( p_box ); \ i_read -= mp4_box_headersize( p_box ); \
if( !( p_box->data.p_data = calloc( 1, sizeof( MP4_Box_data_TYPE_t ) ) ) ) \ if( !( p_box->data.p_payload = calloc( 1, sizeof( MP4_Box_data_TYPE_t ) ) ) ) \
{ \ { \
free( p_buff ); \ free( p_buff ); \
return( 0 ); \ return( 0 ); \
......
...@@ -1656,7 +1656,7 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track, ...@@ -1656,7 +1656,7 @@ static int TrackCreateES( demux_t *p_demux, mp4_track_t *p_track,
i_sample_description_index - 1 ); i_sample_description_index - 1 );
if( !p_sample || if( !p_sample ||
( !p_sample->data.p_data && p_track->fmt.i_cat != SPU_ES ) ) ( !p_sample->data.p_payload && p_track->fmt.i_cat != SPU_ES ) )
{ {
msg_Warn( p_demux, "cannot find SampleEntry (track[Id 0x%x])", msg_Warn( p_demux, "cannot find SampleEntry (track[Id 0x%x])",
p_track->i_track_ID ); p_track->i_track_ID );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment