X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=modules%2Fpacketizer%2Fdirac.c;h=0e92cce548529f7b5fa66e6f7d4fbd1653690de8;hb=6da459431abbea07af556699a251673a706ca584;hp=39c48185a60dbddfd43e1fd153157a44e95687a3;hpb=89b6530d8abd99b96b9f33af022022241fe97ee2;p=vlc diff --git a/modules/packetizer/dirac.c b/modules/packetizer/dirac.c index 39c48185a6..0e92cce548 100644 --- a/modules/packetizer/dirac.c +++ b/modules/packetizer/dirac.c @@ -23,7 +23,7 @@ /* Dirac packetizer, formed of three parts: * 1) Bitstream synchroniser (dirac_DoSync) - * - Given an arbitary sequence of bytes, extract whole Dirac Data Units + * - Given an arbitrary sequence of bytes, extract whole Dirac Data Units * - Maps timestamps in supplied block_t's to the extracted Data Unit * A time stamp applies to the next Data Unit to commence at, or after * the first byte of the block_t with the timestamp. @@ -70,8 +70,8 @@ #include #include -#include "vlc_bits.h" -#include "vlc_block_helper.h" +#include +#include #define SANITIZE_PREV_PARSE_OFFSET 1 @@ -279,7 +279,7 @@ static int block_ChainToArray( block_t *p_block, block_t ***ppp_array) block_ChainProperties( p_block, &i_num_blocks, NULL, NULL ); *ppp_array = calloc( i_num_blocks, sizeof( block_t* ) ); - if( !ppp_array ) return 0; + if( !*ppp_array ) return 0; for( int i = 0; i < i_num_blocks; i++ ) { @@ -922,8 +922,7 @@ static int dirac_InspectDataUnit( decoder_t *p_dec, block_t **pp_block, block_t * - required for ogg muxing * - useful for error checking * - it isn't allowed to change until an eos */ - if( p_es->p_extra ) - free( p_es->p_extra ); + free( p_es->p_extra ); p_es->p_extra = calloc( 1, p_block->i_buffer + 13 ); if( !p_es->p_extra ) {