[FFmpeg-cvslog] mpeg12data: increase size of ff_mpeg1_default_intra_matrix to prevent harmless overreads from crashing

Michael Niedermayer git at videolan.org
Wed Nov 14 03:43:32 CET 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Nov 14 03:17:13 2012 +0100| [7acee6654ccdbadea62e700970f789478febaa0c] | committer: Michael Niedermayer

mpeg12data: increase size of ff_mpeg1_default_intra_matrix to prevent harmless overreads from crashing

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=7acee6654ccdbadea62e700970f789478febaa0c
---

 libavcodec/mpeg12data.c |    2 +-
 libavcodec/mpeg12data.h |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mpeg12data.c b/libavcodec/mpeg12data.c
index d26c5da..e8c4a5d 100644
--- a/libavcodec/mpeg12data.c
+++ b/libavcodec/mpeg12data.c
@@ -27,7 +27,7 @@
 
 #include "mpeg12data.h"
 
-const uint16_t ff_mpeg1_default_intra_matrix[64] = {
+const uint16_t ff_mpeg1_default_intra_matrix[256] = {
         8, 16, 19, 22, 26, 27, 29, 34,
         16, 16, 22, 24, 27, 29, 34, 37,
         19, 22, 26, 27, 29, 34, 34, 38,
diff --git a/libavcodec/mpeg12data.h b/libavcodec/mpeg12data.h
index 0e289b2..65b9485 100644
--- a/libavcodec/mpeg12data.h
+++ b/libavcodec/mpeg12data.h
@@ -32,7 +32,7 @@
 #include "libavutil/rational.h"
 #include "rl.h"
 
-extern const uint16_t ff_mpeg1_default_intra_matrix[64];
+extern const uint16_t ff_mpeg1_default_intra_matrix[];
 extern const uint16_t ff_mpeg1_default_non_intra_matrix[64];
 
 extern const uint16_t ff_mpeg12_vlc_dc_lum_code[12];



More information about the ffmpeg-cvslog mailing list