[FFmpeg-cvslog] avcodec/xpmdec: there are XPM files with dos line endings

Paul B Mahol git at videolan.org
Mon Mar 13 21:41:53 EET 2017


ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Sun Mar 12 23:13:26 2017 +0100| [fbfbd97be25c4da0562ef61e2f27192d1ec4d276] | committer: Paul B Mahol

avcodec/xpmdec: there are XPM files with dos line endings

Signed-off-by: Paul B Mahol <onemda at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fbfbd97be25c4da0562ef61e2f27192d1ec4d276
---

 libavcodec/xpmdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/xpmdec.c b/libavcodec/xpmdec.c
index 605a09d..3c025a6 100644
--- a/libavcodec/xpmdec.c
+++ b/libavcodec/xpmdec.c
@@ -307,7 +307,7 @@ static int xpm_decode_frame(AVCodecContext *avctx, void *data,
     avctx->pix_fmt = AV_PIX_FMT_BGRA;
 
     end = avpkt->data + avpkt->size;
-    while (memcmp(ptr, "/* XPM */\n", 10) && ptr < end - 10)
+    while (memcmp(ptr, "/* XPM */", 9) && ptr < end - 9)
         ptr++;
 
     if (ptr >= end) {



More information about the ffmpeg-cvslog mailing list