summaryrefslogtreecommitdiff
path: root/thirdparty/libwebp/src/dec/frame_dec.c
diff options
context:
space:
mode:
Diffstat (limited to 'thirdparty/libwebp/src/dec/frame_dec.c')
-rw-r--r--thirdparty/libwebp/src/dec/frame_dec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/thirdparty/libwebp/src/dec/frame_dec.c b/thirdparty/libwebp/src/dec/frame_dec.c
index 04609a8e56..91ca1f8609 100644
--- a/thirdparty/libwebp/src/dec/frame_dec.c
+++ b/thirdparty/libwebp/src/dec/frame_dec.c
@@ -705,7 +705,7 @@ static int AllocateMemory(VP8Decoder* const dec) {
+ cache_size + alpha_size + WEBP_ALIGN_CST;
uint8_t* mem;
- if (needed != (size_t)needed) return 0; // check for overflow
+ if (!CheckSizeOverflow(needed)) return 0; // check for overflow
if (needed > dec->mem_size_) {
WebPSafeFree(dec->mem_);
dec->mem_size_ = 0;