On Fri, Mar 28, 2014 at 04:41:46PM +0530, Nidhi Makhijani wrote:
> ---
>  libavformat/nutdec.c | 2 ++
>  1 file changed, 2 insertions(+)

Use

nutdec: Check malloc() calls

as log message.

> --- a/libavformat/nutdec.c
> +++ b/libavformat/nutdec.c
> @@ -326,6 +326,8 @@ static int decode_main_header(NUTContext *nut)
>  
>      nut->stream = av_mallocz(sizeof(StreamContext) * stream_count);
> +    if (!nut->stream)
> +      return AVERROR(ENOMEM);
>      for (i = 0; i < stream_count; i++)
>          avformat_new_stream(s, NULL);

Notice that indentation is off compared to the surrounding code.
We use 4 spaces indentation, not two.

That file contains a bunch more unchecked malloc calls.  Please locate
those and check them as well.

Diego
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to