[libav-commits] dv: Drop a spurious check

Luca Barbato git at libav.org
Sat Nov 15 13:00:23 CET 2014


Module: libav
Branch: master
Commit: 74d7db586a2e9aeb107e357739c7e4dde0b6991c

Author:    Luca Barbato <lu_zero at gentoo.org>
Committer: Vittorio Giovara <vittorio.giovara at gmail.com>
Date:      Wed Nov 12 19:10:39 2014 +0100

dv: Drop a spurious check

The buffer is always valid.

Bug-Id: CID 700682

---

 libavcodec/dvdec.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/dvdec.c b/libavcodec/dvdec.c
index a1235d3..bdf3eea 100644
--- a/libavcodec/dvdec.c
+++ b/libavcodec/dvdec.c
@@ -383,8 +383,8 @@ static int dvvideo_decode_frame(AVCodecContext *avctx, void *data,
     vsc_pack = buf + 80 * 5 + 48 + 5;
     if (*vsc_pack == dv_video_control) {
         apt    = buf[4] & 0x07;
-        is16_9 = (vsc_pack && ((vsc_pack[2] & 0x07) == 0x02 ||
-                               (!apt && (vsc_pack[2] & 0x07) == 0x07)));
+        is16_9 = (vsc_pack[2] & 0x07) == 0x02 ||
+                 (!apt && (vsc_pack[2] & 0x07) == 0x07);
         ff_set_sar(avctx, s->sys->sar[is16_9]);
     }
 



More information about the libav-commits mailing list