diff --git a/test/data/2-out-of-read-Poc b/test/data/2-out-of-read-Poc new file mode 100644 index 00000000..6421044a Binary files /dev/null and b/test/data/2-out-of-read-Poc differ diff --git a/tests/bugfixes/github/test_issue_366.py b/tests/bugfixes/github/test_issue_366.py new file mode 100644 index 00000000..62cf3784 --- /dev/null +++ b/tests/bugfixes/github/test_issue_366.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- + +import system_tests + + +class AdditionOverflowInLoaderTiffGetData(metaclass=system_tests.CaseMeta): + """ + Regression test for bug #366: + https://github.com/Exiv2/exiv2/issues/366 + """ + filename = system_tests.path("$data_path/2-out-of-read-Poc") + commands = ["$exiv2 -ep $filename"] + stdout = [""] + stderr = [ + """Warning: Directory Image, entry 0x0111: Strip 0 is outside of the data area; ignored. +$uncaught_exception $addition_overflow_message +""" + ] + retval = [1]