Commit 22fc7176 authored by Derk-Jan Hartman's avatar Derk-Jan Hartman

* backport [19002]

Copy complete es format descriptor when extra data is added.
parent 3cbd368b
......@@ -611,11 +611,8 @@ static int DecoderDecode( decoder_t *p_dec, block_t *p_block )
{
if( p_packetizer->fmt_out.i_extra && !p_dec->fmt_in.i_extra )
{
p_dec->fmt_in.i_extra = p_packetizer->fmt_out.i_extra;
p_dec->fmt_in.p_extra = malloc( p_dec->fmt_in.i_extra );
memcpy( p_dec->fmt_in.p_extra,
p_packetizer->fmt_out.p_extra,
p_dec->fmt_in.i_extra );
es_format_Clean( &p_dec->fmt_in );
es_format_Copy( &p_dec->fmt_in, &p_packetizer->fmt_out );
}
while( p_packetized_block )
......@@ -682,11 +679,8 @@ static int DecoderDecode( decoder_t *p_dec, block_t *p_block )
{
if( p_packetizer->fmt_out.i_extra && !p_dec->fmt_in.i_extra )
{
p_dec->fmt_in.i_extra = p_packetizer->fmt_out.i_extra;
p_dec->fmt_in.p_extra = malloc( p_dec->fmt_in.i_extra );
memcpy( p_dec->fmt_in.p_extra,
p_packetizer->fmt_out.p_extra,
p_dec->fmt_in.i_extra );
es_format_Clean( &p_dec->fmt_in );
es_format_Copy( &p_dec->fmt_in, &p_packetizer->fmt_out );
}
while( p_packetized_block )
......
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