Commit 520894c6 authored by Janne Grunau's avatar Janne Grunau Committed by Ronald S. Bultje

fuzzer: prevent unwanted integer promotion in r32le

Fixes an undefined shift in
clusterfuzz-testcase-minimized-dav1d_fuzzer-5685383740784640. Credits to
oss-fuzz.
parent 13f3658b
......@@ -33,7 +33,7 @@
#include <dav1d/dav1d.h>
static unsigned r32le(const uint8_t *const p) {
return (p[3] << 24U) | (p[2] << 16U) | (p[1] << 8U) | p[0];
return ((uint32_t)p[3] << 24U) | (p[2] << 16U) | (p[1] << 8U) | p[0];
}
// expects ivf input
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment