]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/voc_packet.c
avcodec/cbs_h26[45]: Remove redundant enum constants
[ffmpeg] / libavformat / voc_packet.c
index 1e2e19e1c36b97b34b032e74f7c76348d21bacbe..9d7d2025cd7c2a22327531fd68ae9761559c394c 100644 (file)
@@ -44,6 +44,8 @@ ff_voc_get_packet(AVFormatContext *s, AVPacket *pkt, AVStream *st, int max_size)
                        AVINDEX_KEYFRAME);
 
     while (!voc->remaining_size) {
+        if (max_size < 4)
+            max_size = 0;
         type = avio_r8(pb);
         if (type == VOC_TYPE_EOF)
             return AVERROR_EOF;