mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-13 02:36:17 +03:00
Tests for PCX OOB Access
This commit is contained in:
parent
c7f9e197aa
commit
124f4bb591
BIN
Tests/images/01r_00.pcx
Normal file
BIN
Tests/images/01r_00.pcx
Normal file
Binary file not shown.
|
@ -638,6 +638,9 @@ class TestImage:
|
||||||
assert test_module.PILLOW_VERSION > "7.0.0"
|
assert test_module.PILLOW_VERSION > "7.0.0"
|
||||||
|
|
||||||
def test_overrun(self):
|
def test_overrun(self):
|
||||||
|
""" For overrun completeness, test as:
|
||||||
|
`valgrind pytest -qq Tests/test_image.py::TestImage::test_overrun | grep decode.c`
|
||||||
|
"""
|
||||||
for file in [
|
for file in [
|
||||||
"fli_overrun.bin",
|
"fli_overrun.bin",
|
||||||
"sgi_overrun.bin",
|
"sgi_overrun.bin",
|
||||||
|
@ -645,6 +648,7 @@ class TestImage:
|
||||||
"sgi_overrun_expandrow2.bin",
|
"sgi_overrun_expandrow2.bin",
|
||||||
"pcx_overrun.bin",
|
"pcx_overrun.bin",
|
||||||
"pcx_overrun2.bin",
|
"pcx_overrun2.bin",
|
||||||
|
"01r_00.pcx",
|
||||||
]:
|
]:
|
||||||
with Image.open(os.path.join("Tests/images", file)) as im:
|
with Image.open(os.path.join("Tests/images", file)) as im:
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user