]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/lagarith.c
lavc/qsvenc: no need to include h264.h for jpeg encoder
[ffmpeg] / libavcodec / lagarith.c
index d88c5f5ae7fbded8b621cbc7d68000b1da7363a9..59169be5dea5231324fd8149f333ae02d6df1059 100644 (file)
@@ -546,6 +546,7 @@ static int lag_decode_frame(AVCodecContext *avctx,
     int ret;
 
     p->key_frame = 1;
+    p->pict_type = AV_PICTURE_TYPE_I;
 
     frametype = buf[0];
 
@@ -668,9 +669,6 @@ static int lag_decode_frame(AVCodecContext *avctx,
 
         if ((ret = ff_thread_get_buffer(avctx, &frame, 0)) < 0)
             return ret;
-        if (buf_size <= offset_ry || buf_size <= offset_gu || buf_size <= offset_bv) {
-            return AVERROR_INVALIDDATA;
-        }
 
         if (offset_ry >= buf_size ||
             offset_gu >= buf_size ||