Commit fca30832 authored by Carl Eugen Hoyos's avatar Carl Eugen Hoyos

lavf/img2dec: Reduce the probe score for incomplete jpgs.

Ensures that probing doesn't finish prematurely for small files.
parent f28299da
...@@ -756,7 +756,7 @@ static int jpeg_probe(AVProbeData *p) ...@@ -756,7 +756,7 @@ static int jpeg_probe(AVProbeData *p)
if (state == EOI) if (state == EOI)
return AVPROBE_SCORE_EXTENSION + 1; return AVPROBE_SCORE_EXTENSION + 1;
if (state == SOS) if (state == SOS)
return AVPROBE_SCORE_EXTENSION / 2 + 1; return AVPROBE_SCORE_EXTENSION / 2;
return AVPROBE_SCORE_EXTENSION / 8; return AVPROBE_SCORE_EXTENSION / 8;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment