diff options
author | Ondřej Surý <ondrej@sury.org> | 2016-07-12 13:37:34 +0200 |
---|---|---|
committer | Ondřej Surý <ondrej@sury.org> | 2016-07-14 10:39:41 +0200 |
commit | bd0b820b8647feefcace20ae13856f6028c6a4dd (patch) | |
tree | dded00ed178461cc4c62b53b19215d2f49d819de /tests/tga | |
parent | b070a263315841ddcb1195ea177e862605692784 (diff) | |
download | libgd-bd0b820b8647feefcace20ae13856f6028c6a4dd.tar.gz |
Tests for #248
Diffstat (limited to 'tests/tga')
-rw-r--r-- | tests/tga/.gitignore | 1 | ||||
-rw-r--r-- | tests/tga/CMakeLists.txt | 1 | ||||
-rw-r--r-- | tests/tga/Makemodule.am | 4 | ||||
-rw-r--r-- | tests/tga/bug00248.c | 14 | ||||
-rw-r--r-- | tests/tga/bug00248.tga | bin | 0 -> 816 bytes |
5 files changed, 19 insertions, 1 deletions
diff --git a/tests/tga/.gitignore b/tests/tga/.gitignore index 14bf59f..826de62 100644 --- a/tests/tga/.gitignore +++ b/tests/tga/.gitignore @@ -1,4 +1,5 @@ /bug00084 /bug00247 /bug00247a +/bug00248 /tga_null diff --git a/tests/tga/CMakeLists.txt b/tests/tga/CMakeLists.txt index 52a4223..585f0b8 100644 --- a/tests/tga/CMakeLists.txt +++ b/tests/tga/CMakeLists.txt @@ -3,6 +3,7 @@ LIST(APPEND TESTS_FILES bug00084 bug00247 bug00247a + bug00248 ) ADD_GD_TESTS() diff --git a/tests/tga/Makemodule.am b/tests/tga/Makemodule.am index 9846fb6..e351a70 100644 --- a/tests/tga/Makemodule.am +++ b/tests/tga/Makemodule.am @@ -2,10 +2,12 @@ libgd_test_programs += \ tga/bug00084 \ tga/bug00247 \ tga/bug00247a \ + tga/bug00248 \ tga/tga_null EXTRA_DIST += \ tga/CMakeLists.txt \ tga/bug00084.tga \ tga/bug00247.tga \ - tga/bug00247a.tga + tga/bug00247a.tga \ + tga/bug00248.tga diff --git a/tests/tga/bug00248.c b/tests/tga/bug00248.c new file mode 100644 index 0000000..5eb6046 --- /dev/null +++ b/tests/tga/bug00248.c @@ -0,0 +1,14 @@ +#include <stdio.h> + +#include "gd.h" +#include "gdtest.h" + +int main(int argc, char **argv) +{ + gdImagePtr im; + FILE *fp = gdTestFileOpen("tga/bug00248.tga"); + im = gdImageCreateFromTga(fp); + gdTestAssert(im == NULL); + fclose(fp); + return gdNumFailures(); +} diff --git a/tests/tga/bug00248.tga b/tests/tga/bug00248.tga Binary files differnew file mode 100644 index 0000000..f0a56f4 --- /dev/null +++ b/tests/tga/bug00248.tga |