[Swfdec] Branch 'as' - libswfdec/swfdec_swf_decoder.c
Benjamin Otte
company at kemper.freedesktop.org
Wed Jun 13 10:37:16 PDT 2007
libswfdec/swfdec_swf_decoder.c | 4 ++++
1 files changed, 4 insertions(+)
New commits:
diff-tree bc7113af3746577aab5a3fd69e30394070d3517c (from 325531065c64b6b31202f2f3b0746cb5f8d501ea)
Author: Benjamin Otte <otte at gnome.org>
Date: Wed Jun 13 19:37:45 2007 +0200
when the rate is 0, set it to 1
diff --git a/libswfdec/swfdec_swf_decoder.c b/libswfdec/swfdec_swf_decoder.c
index 66c6e34..33fb719 100644
--- a/libswfdec/swfdec_swf_decoder.c
+++ b/libswfdec/swfdec_swf_decoder.c
@@ -239,6 +239,10 @@ swf_parse_header2 (SwfdecSwfDecoder * s)
dec->height = MAX (0, ceil (rect.y1 / SWFDEC_TWIPS_SCALE_FACTOR));
swfdec_bits_syncbits (&s->b);
dec->rate = swfdec_bits_get_u16 (&s->b);
+ if (dec->rate == 0) {
+ SWFDEC_INFO ("rate is 0, setting to 1");
+ dec->rate = 1;
+ }
SWFDEC_LOG ("rate = %g", dec->rate / 256.0);
dec->frames_total = swfdec_bits_get_u16 (&s->b);
SWFDEC_LOG ("n_frames = %d", dec->frames_total);
More information about the Swfdec
mailing list