aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <ceffmpeg@gmail.com>2019-12-13 19:10:15 +0100
committerCarl Eugen Hoyos <ceffmpeg@gmail.com>2019-12-14 09:49:58 +0100
commit193143486e8a7b1108147b1ea44134b5a80e5e17 (patch)
tree96dfa782d43668df0d594fdae4e661d62ce14670
parent24424a6516f8adc4c73a2fe00fa106b0e49abafd (diff)
downloadffmpeg-193143486e8a7b1108147b1ea44134b5a80e5e17.tar.gz
lavc/pnmdec: Fix 16bit decoding.
Regression since cdb5479c Reported by irc user tTh from Mixart-Myrys
-rw-r--r--libavcodec/pnmdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/pnmdec.c b/libavcodec/pnmdec.c
index 958c5e43b0..dbcaef3884 100644
--- a/libavcodec/pnmdec.c
+++ b/libavcodec/pnmdec.c
@@ -143,7 +143,7 @@ static int pnm_decode_frame(AVCodecContext *avctx, void *data,
v = (*s->bytestream++)&1;
} else {
/* read a sequence of digits */
- for (k = 0; k < 5 && c <= 9; k += 1) {
+ for (k = 0; k < 6 && c <= 9; k += 1) {
v = 10*v + c;
c = (*s->bytestream++) - '0';
}