PNM loader: Fix reading PNM bitmaps.

Attempting to read a PNM bitmap (ASCII format) would cause a lockup due
to infinite loop, and in certain cases write access outside allocated
memory.

Fixes CVE-2016-6348 (out-of-bounds writes ... presumably - CVE text not
disclosed yet).
Found by Neelima Krishnan, Intel Corporation.
This commit is contained in:
Kim Woelders 2016-07-30 16:44:57 +02:00
parent 9780f8dbc4
commit f6d902efd9
1 changed files with 1 additions and 0 deletions

View File

@ -179,6 +179,7 @@ load(ImlibImage * im, ImlibProgressFunction progress,
goto quit_error;
ptr2++;
i++;
x++;
}
}
if (progress &&