[SCM] libav/experimental: 1 goto 1 fix

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 15:46:16 UTC 2013


The following commit has been merged in the experimental branch:
commit 8cb90572a2bfc8565c387af869564529636c5664
Author: Michael Niedermayer <michaelni at gmx.at>
Date:   Mon Feb 6 11:21:26 2006 +0000

    1 goto 1 fix
    
    Originally committed as revision 4946 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c
index ba641f3..a7ae07b 100644
--- a/libavcodec/mpegvideo.c
+++ b/libavcodec/mpegvideo.c
@@ -231,6 +231,10 @@ void ff_write_quant_matrix(PutBitContext *pb, int16_t *matrix){
 const uint8_t *ff_find_start_code(const uint8_t * restrict p, const uint8_t *end, uint32_t * restrict state){
     int i;
 
+    assert(p<=end);
+    if(p>=end)
+        return end;
+
     for(i=0; i<3; i++){
         uint32_t tmp= *state << 8;
         *state= tmp + *(p++);

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list