Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2020-02-16 22:18:11 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2020-05-19 18:17:36 +0300
commit824c773263c7f749d815abc9948eac7a195a0514 (patch)
treeb3690ce88572b456ef73184a626f9072a5207ad7 /libswscale
parent83b2cc152d772d79141235233662b2080ec909c2 (diff)
swscale/output: Fix integer overflow in alpha computation in yuv2gbrp16_full_X_c()
Fixes: signed integer overflow: 524280 * 4432 cannot be represented in type 'int' Fixes: ticket8322 Found-by: Suhwan Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 49ba1879add99d3f64d70d34fb0255c8a49d4b28) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libswscale')
-rw-r--r--libswscale/output.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libswscale/output.c b/libswscale/output.c
index 74d420e613..4f70b1e331 100644
--- a/libswscale/output.c
+++ b/libswscale/output.c
@@ -2275,7 +2275,7 @@ yuv2gbrp16_full_X_c(SwsContext *c, const int16_t *lumFilter,
A = -0x40000000;
for (j = 0; j < lumFilterSize; j++)
- A += alpSrc[j][i] * lumFilter[j];
+ A += alpSrc[j][i] * (unsigned)lumFilter[j];
A >>= 1;
A += 0x20002000;