aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClément Bœsch <ubitux@gmail.com>2016-07-15 10:29:14 +0200
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2016-07-15 10:36:05 +0200
commit77726d32a872ad500434fd8799b289cf56215047 (patch)
treeef1e38f28e68cfa2e8a19e5aade562cc4304d24a
parente1023aa1dd0cbacde77e142ec79dba71c0d444aa (diff)
downloadffmpeg-77726d32a872ad500434fd8799b289cf56215047.tar.gz
lavf/vplayerdec: Improve auto-detection.
Fixes the incorrect detection of 16_selma_OneFrame_QP39.yuv (gray16le rawvideo) as vplayer format.
-rw-r--r--libavformat/vplayerdec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/vplayerdec.c b/libavformat/vplayerdec.c
index 897c4083b6..49943d0d0e 100644
--- a/libavformat/vplayerdec.c
+++ b/libavformat/vplayerdec.c
@@ -36,8 +36,8 @@ static int vplayer_probe(AVProbeData *p)
char c;
const unsigned char *ptr = p->buf;
- if ((sscanf(ptr, "%*d:%*d:%*d.%*d%c", &c) == 1 ||
- sscanf(ptr, "%*d:%*d:%*d%c", &c) == 1) && strchr(": =", c))
+ if ((sscanf(ptr, "%*3d:%*2d:%*2d.%*2d%c", &c) == 1 ||
+ sscanf(ptr, "%*3d:%*2d:%*2d%c", &c) == 1) && strchr(": =", c))
return AVPROBE_SCORE_MAX;
return 0;
}