Merge commit '42cf7f91f1e9dabf494ff469d8f67ac8b33b0f63'
[ffmpeg.git] / libavcodec / pnm_parser.c
index a7d70b9..bdd7f2b 100644 (file)
@@ -56,15 +56,8 @@ retry:
             }
             goto retry;
         }
-#if 0
-        if (pc->index && pc->index * 2 + AV_INPUT_BUFFER_PADDING_SIZE < pc->buffer_size && buf_size > pc->index) {
-            memcpy(pc->buffer + pc->index, buf, pc->index);
-            pc->index += pc->index;
-            buf       += pc->index;
-            buf_size  -= pc->index;
-            goto retry;
-        }
-#endif
+        next = END_NOT_FOUND;
+    } else if (pnmctx.type < 4) {
         next = END_NOT_FOUND;
     } else {
         next = pnmctx.bytestream - pnmctx.bytestream_start