[FFmpeg-devel] [PATCHv+ BUG REPORT] Various memory leaks

Vitor Sessak vitor1001
Fri Feb 19 21:22:21 CET 2010


Reimar D?ffinger wrote:
> On Fri, Feb 19, 2010 at 06:18:47PM +0100, Vitor Sessak wrote:
>> -        if (av_new_packet(pkt, 4 + pkt_size))
>> -            return AVERROR(ENOMEM);
>> +        if ((ret = av_new_packet(pkt, 4 + pkt_size)))
>> +            return ret;
> 
> Should check for < 0 only, not != 0.
> Also I'd be in favour of doing the assignment outside the if.
> The rest seems fine to me, though a bit inconsistent with sometimes
> an empty line between assignment and if and sometimes without.

Thanks for the review, committed dsicin and xa. VP6 still waiting for 
review.

-Vitor



More information about the ffmpeg-devel mailing list