summaryrefslogtreecommitdiffstats
path: root/tests/imgPhoto.test
diff options
context:
space:
mode:
authoroehhar <harald.oehlmann@elmicron.de>2019-03-05 15:18:57 (GMT)
committeroehhar <harald.oehlmann@elmicron.de>2019-03-05 15:18:57 (GMT)
commit66463b7f19d9e14296571c368b1a5710c7d455fd (patch)
treef8d6c82dd035f7394f9c0895f79d70c235d215a9 /tests/imgPhoto.test
parentb3fab43c803e6cf64fd5b33e58e27d0c9b7b5936 (diff)
parent9470b0e3ea0f2b6495852aa069a0e8b06d85d774 (diff)
downloadtk-66463b7f19d9e14296571c368b1a5710c7d455fd.zip
tk-66463b7f19d9e14296571c368b1a5710c7d455fd.tar.gz
tk-66463b7f19d9e14296571c368b1a5710c7d455fd.tar.bz2
gif read not complete on overflow image - information missinterpreted if following subimage is querried [4da2191b]
Diffstat (limited to 'tests/imgPhoto.test')
-rw-r--r--tests/imgPhoto.test33
1 files changed, 33 insertions, 0 deletions
diff --git a/tests/imgPhoto.test b/tests/imgPhoto.test
index 4b2e3cf..eba3355 100644
--- a/tests/imgPhoto.test
+++ b/tests/imgPhoto.test
@@ -1754,6 +1754,39 @@ test imgPhoto-14.5 {Bug [fbaed1f66b] - GIF decoder with deferred clear code} -se
image create photo -file $fileName -format "gif -index 2"
} -returnCodes error -result {no image data for this index}
+test imgPhoto-14.6 {Access Subimage after Subimage with buffer overflow. Ticket 4da2191b} -setup {
+ set data {
+ R0lGODlhYwA5APcAAAAAAIAAAACAAICAAAAAgIAAgACAgICAgAysnGy8hKzM
+ hASs3MTcjAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
+ AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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yZiyVIvXr77ODPEy5g9T4zMWfTEzXdNz1VbWvXn
+ uqldP1TAOrbshqBb314Y2W7n3Qdpv7UNPCHpycUVbv6dnODy5sqzQldIe8H0
+ hciva9/Ovbv37+BzBgE7ACH5BAFkAAMALAAAAAAEAAQAAAMEKLrckgA7
+ }
+} -body {
+ image create photo photo1 -data $data -format "GIF -index 1"
+} -cleanup {
+ catch {image delete photo1}
+} -result photo1
+
test imgPhoto-15.1 {photo images can fail to allocate memory gracefully} -constraints {
nonPortable
} -body {