This also fixes a buffer overrun when MP4_VERBOSE is defined and i_count
is 0
VLC_UNUSED(i_reserved);
MP4_GET2BYTES( i_reserved );
MP4_GET2BYTES( i_count );
VLC_UNUSED(i_reserved);
MP4_GET2BYTES( i_reserved );
MP4_GET2BYTES( i_count );
+ if( i_count == 0 )
+ MP4_READBOX_EXIT( 1 );
p_sidx_data->i_reference_count = i_count;
p_sidx_data->p_items = vlc_alloc( i_count, sizeof( MP4_Box_sidx_item_t ) );
p_sidx_data->i_reference_count = i_count;
p_sidx_data->p_items = vlc_alloc( i_count, sizeof( MP4_Box_sidx_item_t ) );