[SCM] libav/experimental: (m)jpeg pad/flush with 1 instead of 0, fix by Rik Snel <rsnel at cube.dyndns.org>

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


The following commit has been merged in the experimental branch:
commit 580b82fa244bcb668069ca0a8803258be7ba77bb
Author: Arpi <arpi at thot.banki.hu>
Date:   Sat Jan 26 00:22:25 2002 +0000

    (m)jpeg pad/flush with 1 instead of 0, fix by Rik Snel <rsnel at cube.dyndns.org>
    
    Originally committed as revision 280 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavcodec/common.c b/libavcodec/common.c
index fb73c7e..b3436eb 100644
--- a/libavcodec/common.c
+++ b/libavcodec/common.c
@@ -157,6 +157,7 @@ void jput_bits(PutBitContext *s, int n, unsigned int value)
 void jflush_put_bits(PutBitContext *s)
 {
     unsigned int b;
+    s->bit_buf |= ~1U >> s->bit_cnt; /* set all the unused bits to one */
 
     while (s->bit_cnt > 0) {
         b = s->bit_buf >> 24;

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list