avcodec/dds: Fix runtime error: left shift of 1 by 31 places cannot be represented...
authorMichael Niedermayer <michael@niedermayer.cc>
Sat, 6 May 2017 20:31:23 +0000 (22:31 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Sat, 6 May 2017 21:23:39 +0000 (23:23 +0200)
Fixes: 1380/clusterfuzz-testcase-minimized-650122545122508

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/dds.c

index 84b440f..468763e 100644 (file)
@@ -39,7 +39,7 @@
 
 #define DDPF_FOURCC    (1 <<  2)
 #define DDPF_PALETTE   (1 <<  5)
-#define DDPF_NORMALMAP (1 << 31)
+#define DDPF_NORMALMAP (1U << 31)
 
 enum DDSPostProc {
     DDS_NONE = 0,