[Ffmpeg-devel] [PATCH] init wb codec on definition
Måns Rullgård
mans
Wed Mar 7 22:25:27 CET 2007
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.
--
M?ns Rullg?rd
mans at mansr.com
More information about the ffmpeg-devel
mailing list