]> git.sesse.net Git - ffmpeg/commitdiff
avformat/segafilmenc: Fix undefined left shift of 1 by 31 places
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Tue, 14 Jan 2020 03:13:30 +0000 (04:13 +0100)
committerMichael Niedermayer <michael@niedermayer.cc>
Tue, 14 Jan 2020 22:00:35 +0000 (23:00 +0100)
by changing the type to unsigned.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavformat/segafilmenc.c

index 812d0ad64e947af82f72c304b2e78413961c6225..d721ec38fa90d02c16f171f903ed0225851e4aa1 100644 (file)
@@ -70,7 +70,7 @@ static int film_write_packet_to_header(AVFormatContext *format_context, FILMPack
         info2 = pkt->duration;
         /* The top bit being set indicates a key frame */
         if (!pkt->keyframe)
-            info1 |= (1 << 31);
+            info1 |= 1U << 31;
     }
 
     /* Write the 16-byte sample info packet to the STAB chunk in the header */