[FFmpeg-cvslog] r16012 - trunk/libavcodec/msrledec.c
kostya
subversion
Sat Dec 6 10:01:12 CET 2008
Author: kostya
Date: Sat Dec 6 10:01:11 2008
New Revision: 16012
Log:
Print out some errors found during MS RLE decoding
Modified:
trunk/libavcodec/msrledec.c
Modified: trunk/libavcodec/msrledec.c
==============================================================================
--- trunk/libavcodec/msrledec.c (original)
+++ trunk/libavcodec/msrledec.c Sat Dec 6 10:01:11 2008
@@ -145,8 +145,10 @@ static int msrle_decode_8_16_24_32(AVCod
p2 = *src++;
if(p2 == 0) { //End-of-line
output = pic->data[0] + (--line) * pic->linesize[0];
- if (line < 0)
+ if (line < 0){
+ av_log(avctx, AV_LOG_ERROR, "Next line is beyond picture bounds\n");
return -1;
+ }
pos = 0;
continue;
} else if(p2 == 1) { //End-of-picture
@@ -155,8 +157,10 @@ static int msrle_decode_8_16_24_32(AVCod
p1 = *src++;
p2 = *src++;
line -= p2;
- if (line < 0)
+ if (line < 0){
+ av_log(avctx, AV_LOG_ERROR, "Skip beyond picture bounds\n");
return -1;
+ }
pos += p1;
output = pic->data[0] + line * pic->linesize[0] + pos * (depth >> 3);
continue;
More information about the ffmpeg-cvslog
mailing list