summaryrefslogtreecommitdiff
path: root/libavcodec/msrledec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2010-11-02 01:19:09 +0000
committerMichael Niedermayer <michaelni@gmx.at>2010-11-02 01:19:09 +0000
commit81a646140f80c3e15c1e68883a5ecfb9b2bc8a6a (patch)
tree2f21ea8c3b58220204d42dccce422020e3e04731 /libavcodec/msrledec.c
parent94ee6c100dea2f66088f92cae4e16676197e0151 (diff)
remove impossible condition from msrle_decode_pal4()
Originally committed as revision 25631 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/msrledec.c')
-rw-r--r--libavcodec/msrledec.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/libavcodec/msrledec.c b/libavcodec/msrledec.c
index 2f27d20371..d3d3601756 100644
--- a/libavcodec/msrledec.c
+++ b/libavcodec/msrledec.c
@@ -75,8 +75,7 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic,
odd_pixel = stream_byte & 1;
rle_code = (stream_byte + 1) / 2;
extra_byte = rle_code & 0x01;
- if ((row_ptr + pixel_ptr + stream_byte > frame_size) ||
- (row_ptr < 0)) {
+ if (row_ptr + pixel_ptr + stream_byte > frame_size) {
av_log(avctx, AV_LOG_ERROR, " MS RLE: frame ptr just went out of bounds (1)\n");
return -1;
}
@@ -101,8 +100,7 @@ static int msrle_decode_pal4(AVCodecContext *avctx, AVPicture *pic,
}
} else {
// decode a run of data
- if ((row_ptr + pixel_ptr + stream_byte > frame_size) ||
- (row_ptr < 0)) {
+ if (row_ptr + pixel_ptr + stream_byte > frame_size) {
av_log(avctx, AV_LOG_ERROR, " MS RLE: frame ptr just went out of bounds (1)\n");
return -1;
}