]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/iff.c
mpegaudioenc: Remove broken integer-only quantization code path
[ffmpeg] / libavcodec / iff.c
index eda42e9c4cd3b4bca44e25d46ab4c2505ff1770a..1ee02bd506a6346097c7bd9c127e77de941da5d6 100644 (file)
@@ -289,7 +289,7 @@ static int decode_frame_ilbm(AVCodecContext *avctx,
             }
         }
     } else if (avctx->pix_fmt == AV_PIX_FMT_PAL8 || avctx->pix_fmt == AV_PIX_FMT_GRAY8) { // IFF-PBM
-        for (y = 0; y < avctx->height; y++) {
+        for (y = 0; y < avctx->height && buf < buf_end; y++) {
             uint8_t *row = &s->frame.data[0][y * s->frame.linesize[0]];
             memcpy(row, buf, FFMIN(avctx->width, buf_end - buf));
             buf += avctx->width + (avctx->width % 2); // padding if odd
@@ -369,6 +369,7 @@ static av_cold int decode_end(AVCodecContext *avctx)
 
 AVCodec ff_iff_ilbm_decoder = {
     .name           = "iff_ilbm",
+    .long_name      = NULL_IF_CONFIG_SMALL("IFF ILBM"),
     .type           = AVMEDIA_TYPE_VIDEO,
     .id             = AV_CODEC_ID_IFF_ILBM,
     .priv_data_size = sizeof(IffContext),
@@ -376,11 +377,11 @@ AVCodec ff_iff_ilbm_decoder = {
     .close          = decode_end,
     .decode         = decode_frame_ilbm,
     .capabilities   = CODEC_CAP_DR1,
-    .long_name      = NULL_IF_CONFIG_SMALL("IFF ILBM"),
 };
 
 AVCodec ff_iff_byterun1_decoder = {
     .name           = "iff_byterun1",
+    .long_name      = NULL_IF_CONFIG_SMALL("IFF ByteRun1"),
     .type           = AVMEDIA_TYPE_VIDEO,
     .id             = AV_CODEC_ID_IFF_BYTERUN1,
     .priv_data_size = sizeof(IffContext),
@@ -388,5 +389,4 @@ AVCodec ff_iff_byterun1_decoder = {
     .close          = decode_end,
     .decode         = decode_frame_byterun1,
     .capabilities   = CODEC_CAP_DR1,
-    .long_name      = NULL_IF_CONFIG_SMALL("IFF ByteRun1"),
 };