[Ffmpeg-devel] [PATCH] init wb codec on definition

Benoit Fouet benoit.fouet
Wed Mar 7 22:44:07 CET 2007


Hi,

M?ns Rullg?rd wrote:
> Benoit Fouet <benoit.fouet at purplelabs.com> writes:
>
>   
>> Hi,
>>
>> in amr.c, only the amr_wb_encode_frame function initializes its context
>> on a different line as it defines it. This patch just move the
>> initialization on context definition.
>>
>> Ben
>>
>> --- libavcodec/amr.c.working	2007-03-07 21:47:56.000000000 +0100
>> +++ libavcodec/amr.c	2007-03-07 22:03:09.000000000 +0100
>> @@ -621,9 +620,9 @@
>>  static int amr_wb_encode_frame(AVCodecContext *avctx,
>>                              unsigned char *frame/*out*/, int buf_size, void *data/*in*/)
>>  {
>> -    AMRWBContext *s;
>> +    AMRWBContext *s = (AMRWBContext*) avctx->priv_data;
>>      int size;
>> -    s = (AMRWBContext*) avctx->priv_data;
>> +
>>     
>
> That cast isn't needed.
>
>   

thanks, i send a separate patch for that too...

Ben





More information about the ffmpeg-devel mailing list