On Tue, May 17, 2016 at 3:21 AM, Michael Niedermayer
<mich...@niedermayer.cc> wrote:
> On Mon, May 16, 2016 at 03:21:43PM -0700, chcunning...@chromium.org wrote:
>> From: Chris Cunningham <chcunning...@chromium.org>
>>
>> Fixes: undefined shift.
>> ---
>>  libavformat/utils.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/libavformat/utils.c b/libavformat/utils.c
>> index 5f5f03e..ad5cfa2 100644
>> --- a/libavformat/utils.c
>> +++ b/libavformat/utils.c
>> @@ -2955,7 +2955,7 @@ enum AVCodecID ff_codec_get_id(const AVCodecTag *tags, 
>> unsigned int tag)
>>
>>  enum AVCodecID ff_get_pcm_codec_id(int bps, int flt, int be, int sflags)
>>  {
>> -    if (bps > 64U)
>> +    if (bps <= 0 || bps > 64U)
>
> the U is no longer needed if < 0 is explicitly checked for

Wouldn't the U check already check for negative, making this change
unnecessary? Well other then checking exactly for 0, i guess.

- Hendrik
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel

Reply via email to