changeset 3361:bcaa5113e311 libavcodec

Ignore overrun in spectral RLE decoding, fixes http://www.missouri.edu/~bah347/gprime/nintendothemesacappellax.wmv
author reimar
date Tue, 27 Jun 2006 12:09:58 +0000
parents 2c4ddf5b9217
children c43fcf831f7c
files wmadec.c
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/wmadec.c	Tue Jun 27 03:11:51 2006 +0000
+++ b/wmadec.c	Tue Jun 27 12:09:58 2006 +0000
@@ -908,7 +908,10 @@
                     level = -level;
                 ptr += run;
                 if (ptr >= eptr)
-                    return -1;
+                {
+                    av_log(NULL, AV_LOG_ERROR, "overflow in spectral RLE, ignoring\n");
+                    break;
+                }
                 *ptr++ = level;
                 /* NOTE: EOB can be omitted */
                 if (ptr >= eptr)