From e4f141ad60afbd721e494975677fbfd8e0ebcb22 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reimar=20D=C3=B6ffinger?= Date: Sun, 31 May 2009 10:44:42 +0000 Subject: [PATCH] One more use for FFMIN. Originally committed as revision 19055 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/lcldec.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libavcodec/lcldec.c b/libavcodec/lcldec.c index 927f77b30b..5225ff0552 100644 --- a/libavcodec/lcldec.c +++ b/libavcodec/lcldec.c @@ -102,9 +102,7 @@ static unsigned int mszh_decomp(const unsigned char * srcptr, int srclen, unsign cnt = (ofs >> 11) + 1; ofs &= 0x7ff; cnt *= 4; - if (destptr_end - destptr < cnt) { - cnt = destptr_end - destptr; - } + cnt = FFMIN(cnt, destptr_end - destptr); av_memcpy_backptr(destptr, ofs, cnt); destptr += cnt; }