From: Jonathan Rosser <[EMAIL PROTECTED]>

If the arithmetic decoder 'runs away' due to a corrupted or erroneous
bitstream, then 0xff bytes are fed in after the inputbuffer is consumed.
This ensures that the arithmetic decoder will output '1' symbols,
terminating decoding.

Signed-off-by: David Flynn <[EMAIL PROTECTED]>
---
 schroedinger/schroarith.h |    5 -----
 1 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/schroedinger/schroarith.h b/schroedinger/schroarith.h
index 5f6c498..37ee21a 100644
--- a/schroedinger/schroarith.h
+++ b/schroedinger/schroarith.h
@@ -207,16 +207,11 @@ _schro_arith_decode_uint (SchroArith *arith, unsigned int 
cont_context,
     unsigned int value_context)
 {
   unsigned int bits=1;
-  int count=0;
 
   while(!_schro_arith_decode_bit (arith, cont_context)) {
     bits <<= 1;
     bits |= _schro_arith_decode_bit (arith, value_context);
     cont_context = arith->contexts[cont_context].next;
-    count++;
-
-    /* FIXME being careful */
-    if (count == 30) break;
   }
   return bits - 1;
 }
-- 
1.5.5



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Schrodinger-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/schrodinger-devel

Reply via email to