]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/mpegpicture.c
avcodec/vorbis: Fix another 1 << 31 > int32_t::max() with 1u.
[ffmpeg] / libavcodec / mpegpicture.c
index 2b72346fb2498b29fe4673c105e1b2a3826df53e..2be670cdbc2305c1b19a2778cfd191a6ddd1e680 100644 (file)
@@ -375,8 +375,10 @@ int ff_mpeg_ref_picture(AVCodecContext *avctx, Picture *dst, Picture *src)
 
     if (src->hwaccel_picture_private) {
         dst->hwaccel_priv_buf = av_buffer_ref(src->hwaccel_priv_buf);
-        if (!dst->hwaccel_priv_buf)
+        if (!dst->hwaccel_priv_buf) {
+            ret = AVERROR(ENOMEM);
             goto fail;
+        }
         dst->hwaccel_picture_private = dst->hwaccel_priv_buf->data;
     }