summaryrefslogtreecommitdiffstats
path: root/generic/tkTextImage.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2012-12-04 17:02:22 (GMT)
committerdgp <dgp@users.sourceforge.net>2012-12-04 17:02:22 (GMT)
commit3f42c9107ec35c5ee5c4375e300ee6f64190b470 (patch)
treecd8002bc80338c375b21e3ec5c47e7c1aee382c3 /generic/tkTextImage.c
parente663907018c3069a94a7917f49cd1375e6c3bdb0 (diff)
parent113feb6ab1ff04f9d02a2e0f4869e33f7a3c5458 (diff)
downloadtk-3f42c9107ec35c5ee5c4375e300ee6f64190b470.zip
tk-3f42c9107ec35c5ee5c4375e300ee6f64190b470.tar.gz
tk-3f42c9107ec35c5ee5c4375e300ee6f64190b470.tar.bz2
[Bug 3588824]: bug in image index handling for weird image names
Diffstat (limited to 'generic/tkTextImage.c')
-rw-r--r--generic/tkTextImage.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/generic/tkTextImage.c b/generic/tkTextImage.c
index 1770cb6..4a98d42 100644
--- a/generic/tkTextImage.c
+++ b/generic/tkTextImage.c
@@ -786,6 +786,10 @@ TkTextImageIndex(
Tcl_HashEntry *hPtr;
TkTextSegment *eiPtr;
+ if (textPtr == NULL) {
+ return 0;
+ }
+
hPtr = Tcl_FindHashEntry(&textPtr->sharedTextPtr->imageTable, name);
if (hPtr == NULL) {
return 0;