aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2016-01-14 03:05:11 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2016-01-15 16:00:31 +0100
commitf0cc6f74fcfed14b7ff7b3fdff66866db8447d73 (patch)
tree057f700add84b81df91ce184e4e059e4dd52df33
parentf5060bce3108acf85b2e5da22d8d9e98858de43a (diff)
downloadffmpeg-f0cc6f74fcfed14b7ff7b3fdff66866db8447d73.tar.gz
swscale/yuv2rgb: Increase YUV2RGB table headroom
This makes SWS more robust Fixes: 07650a772d98aa63b0fed6370dc89037/asan_heap-oob_27ddeaf_2657_2c81ff264dee5d9712cb3251fb9c3bbb.264 Fixes: out of array read Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 8f3a9a8c278acf886f70a1d743bc07b6f9c7b51a) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libswscale/swscale_internal.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/libswscale/swscale_internal.h b/libswscale/swscale_internal.h
index fa119d304c..217e30781f 100644
--- a/libswscale/swscale_internal.h
+++ b/libswscale/swscale_internal.h
@@ -39,8 +39,8 @@
#define STR(s) AV_TOSTRING(s) // AV_STRINGIFY is too long
-#define YUVRGB_TABLE_HEADROOM 256
-#define YUVRGB_TABLE_LUMA_HEADROOM 0
+#define YUVRGB_TABLE_HEADROOM 512
+#define YUVRGB_TABLE_LUMA_HEADROOM 512
#define MAX_FILTER_SIZE SWS_MAX_FILTER_SIZE