[SCM] libav/experimental: Write 0 instead of seeking forward (and leaving bytes uninitalized), fixes odd regression test failure i had.

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 16:11:44 UTC 2013


The following commit has been merged in the experimental branch:
commit 2024c2262b16acdb7fec850766ad06bd494355f7
Author: Michael Niedermayer <michaelni at gmx.at>
Date:   Sat Jan 12 00:15:05 2008 +0000

    Write 0 instead of seeking forward (and leaving bytes uninitalized),
    fixes odd regression test failure i had.
    
    Originally committed as revision 11512 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c
index 5027d73..2c1f542 100644
--- a/libavformat/matroskaenc.c
+++ b/libavformat/matroskaenc.c
@@ -197,7 +197,8 @@ static void put_ebml_void(ByteIOContext *pb, uint64_t size)
         put_ebml_num(pb, size-1, 0);
     else
         put_ebml_num(pb, size-9, 8);
-    url_fseek(pb, currentpos + size, SEEK_SET);
+    while(url_ftell(pb) < currentpos + size)
+        put_byte(pb, 0);
 }
 
 static ebml_master start_ebml_master(ByteIOContext *pb, unsigned int elementid, uint64_t expectedsize)

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list