[Ffmpeg-cvslog] r8525 - trunk/libavcodec/lzw.c

michael subversion
Mon Mar 26 02:54:29 CEST 2007


Author: michael
Date: Mon Mar 26 02:54:29 2007
New Revision: 8525

Modified:
   trunk/libavcodec/lzw.c

Log:
factorize &


Modified: trunk/libavcodec/lzw.c
==============================================================================
--- trunk/libavcodec/lzw.c	(original)
+++ trunk/libavcodec/lzw.c	Mon Mar 26 02:54:29 2007
@@ -78,17 +78,17 @@ static int lzw_get_code(struct LZWState 
             s->bbits += 8;
             s->bs--;
         }
-        c = s->bbuf & s->curmask;
+        c = s->bbuf;
         s->bbuf >>= s->cursize;
     } else { // TIFF
         while (s->bbits < s->cursize) {
             s->bbuf = (s->bbuf << 8) | (*s->pbuf++);
             s->bbits += 8;
         }
-        c = (s->bbuf >> (s->bbits - s->cursize)) & s->curmask;
+        c = s->bbuf >> (s->bbits - s->cursize);
     }
     s->bbits -= s->cursize;
-    return c;
+    return c & s->curmask;
 }
 
 uint8_t* ff_lzw_cur_ptr(LZWState *p)




More information about the ffmpeg-cvslog mailing list