r1115 - in /experimental/ffmpeg/debian/patches: 020_fix_sws_scale_crash series

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Mar 30 20:52:24 UTC 2008


Author: siretart
Date: Sun Mar 30 20:52:23 2008
New Revision: 1115

URL: http://svn.debian.org/wsvn/pkg-multimedia/?sc=1&rev=1115
Log:
if sws_scale is given an invalid context (e.g. a null pointer), the
function will crash because of a null pointer dereference. Add a check
for that here.

Added:
    experimental/ffmpeg/debian/patches/020_fix_sws_scale_crash
Modified:
    experimental/ffmpeg/debian/patches/series

Added: experimental/ffmpeg/debian/patches/020_fix_sws_scale_crash
URL: http://svn.debian.org/wsvn/pkg-multimedia/experimental/ffmpeg/debian/patches/020_fix_sws_scale_crash?rev=1115&op=file
==============================================================================
--- experimental/ffmpeg/debian/patches/020_fix_sws_scale_crash (added)
+++ experimental/ffmpeg/debian/patches/020_fix_sws_scale_crash Sun Mar 30 20:52:23 2008
@@ -1,0 +1,23 @@
+if sws_scale is given an invalid context (e.g. a null pointer), the
+function will crash because of a null pointer dereference. Add a check
+for that here.
+
+Reference:
+http://lists.alioth.debian.org/pipermail/pkg-multimedia-maintainers/2008-March/000965.html
+
+Index: ffmpeg.20080206/libswscale/swscale.c
+===================================================================
+--- ffmpeg.20080206.orig/libswscale/swscale.c	2008-03-28 12:45:33.000000000 +0100
++++ ffmpeg.20080206/libswscale/swscale.c	2008-03-28 16:25:24.000000000 +0100
+@@ -2529,6 +2529,11 @@
+     int i;
+     uint8_t* src2[4]= {src[0], src[1], src[2]};
+     uint32_t pal[256];
++
++    if (!c) {
++        av_log(c, AV_LOG_ERROR, "swScaler: SwsContext invalid\n");
++        return 0;
++    }
+     if (c->sliceDir == 0 && srcSliceY != 0 && srcSliceY + srcSliceH != c->srcH) {
+         av_log(c, AV_LOG_ERROR, "swScaler: slices start in the middle!\n");
+         return 0;

Modified: experimental/ffmpeg/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-multimedia/experimental/ffmpeg/debian/patches/series?rev=1115&op=diff
==============================================================================
--- experimental/ffmpeg/debian/patches/series (original)
+++ experimental/ffmpeg/debian/patches/series Sun Mar 30 20:52:23 2008
@@ -14,5 +14,6 @@
 020_fix_libswscale_pic_code
 #040_early_altivec_detection.diff
 #040_only_use_maltivec_when_needed.diff
+020_fix_sws_scale_crash
 054_h264_mmx_chroma_mc_crash.diff
 300_c++_compliant_headers.diff




More information about the pkg-multimedia-commits mailing list