[FFmpeg-cvslog] cinepak: simplify, use FFMIN()

Michael Niedermayer git at videolan.org
Sat Nov 19 02:09:43 CET 2011


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Nov 16 17:15:15 2011 +0100| [a2b51fe87c49c3ce21c4ae3310be234a9f87795c] | committer: Martin Storsjö

cinepak: simplify, use FFMIN()

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
Signed-off-by: Martin Storsjö <martin at martin.st>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a2b51fe87c49c3ce21c4ae3310be234a9f87795c
---

 libavcodec/cinepak.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/libavcodec/cinepak.c b/libavcodec/cinepak.c
index 0dbdeab..c6edfe6 100644
--- a/libavcodec/cinepak.c
+++ b/libavcodec/cinepak.c
@@ -357,8 +357,7 @@ static int cinepak_decode (CinepakContext *s)
 
     s->data += 10 + s->sega_film_skip_bytes;
 
-    if (num_strips > MAX_STRIPS)
-        num_strips = MAX_STRIPS;
+    num_strips = FFMIN(num_strips, MAX_STRIPS);
 
     for (i=0; i < num_strips; i++) {
         if ((s->data + 12) > eod)



More information about the ffmpeg-cvslog mailing list