---
 libavcodec/wmv2dec.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/libavcodec/wmv2dec.c b/libavcodec/wmv2dec.c
index 8bdf5e1..0a465f3 100644
--- a/libavcodec/wmv2dec.c
+++ b/libavcodec/wmv2dec.c
@@ -86,7 +86,7 @@ static int decode_ext_header(Wmv2Context *w)
     int code;
 
     if (s->avctx->extradata_size < 4)
-        return -1;
+        return AVERROR_INVALIDDATA;
 
     init_get_bits(&gb, s->avctx->extradata, 32);
 
@@ -101,7 +101,7 @@ static int decode_ext_header(Wmv2Context *w)
     code                = get_bits(&gb, 3);
 
     if (code == 0)
-        return -1;
+        return AVERROR_INVALIDDATA;
 
     s->slice_height = s->mb_height / code;
 
@@ -131,7 +131,7 @@ int ff_wmv2_decode_picture_header(MpegEncContext *s)
     }
     s->chroma_qscale = s->qscale = get_bits(&s->gb, 5);
     if (s->qscale <= 0)
-        return -1;
+        return AVERROR_INVALIDDATA;
 
     return 0;
 }
@@ -364,7 +364,7 @@ int ff_wmv2_decode_mb(MpegEncContext *s, int16_t 
block[6][64])
         code = get_vlc2(&s->gb, ff_mb_non_intra_vlc[w->cbp_table_index].table,
                         MB_NON_INTRA_VLC_BITS, 3);
         if (code < 0)
-            return -1;
+            return AVERROR_INVALIDDATA;
         s->mb_intra = (~code & 0x40) >> 6;
 
         cbp = code & 0x3f;
@@ -374,7 +374,7 @@ int ff_wmv2_decode_mb(MpegEncContext *s, int16_t 
block[6][64])
         if (code < 0) {
             av_log(s->avctx, AV_LOG_ERROR,
                    "II-cbp illegal at %d %d\n", s->mb_x, s->mb_y);
-            return -1;
+            return AVERROR_INVALIDDATA;
         }
         /* predict coded block pattern */
         cbp = 0;
-- 
1.8.3.2

_______________________________________________
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to