summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2016-07-21 20:08:50 (GMT)
committerdgp <dgp@users.sourceforge.net>2016-07-21 20:08:50 (GMT)
commit077b98131bbf66a3363e3c450447af6c9edf77cf (patch)
treecd7aaee28e7876e8bfdd77e835c534b13cbe5f98
parent2aa945d6a8109c74d9ff3331fb99a093635e0cd7 (diff)
parenta80e603c517d2682ef25067ac6daf1d2692d5864 (diff)
downloadtk-077b98131bbf66a3363e3c450447af6c9edf77cf.zip
tk-077b98131bbf66a3363e3c450447af6c9edf77cf.tar.gz
tk-077b98131bbf66a3363e3c450447af6c9edf77cf.tar.bz2
[450bb0ecad] Fix corruption [tk busy] creates on OSX.
-rw-r--r--generic/tkBusy.c4
-rw-r--r--generic/tkWindow.c3
2 files changed, 7 insertions, 0 deletions
diff --git a/generic/tkBusy.c b/generic/tkBusy.c
index 65248a2..b36d453 100644
--- a/generic/tkBusy.c
+++ b/generic/tkBusy.c
@@ -433,6 +433,10 @@ MakeTransparentWindowExist(
TkpMakeTransparentWindowExist(tkwin, parent);
+ if (winPtr->window == None) {
+ return; /* Platform didn't make Window. */
+ }
+
dispPtr = winPtr->dispPtr;
hPtr = Tcl_CreateHashEntry(&dispPtr->winTable, (char *) winPtr->window,
&notUsed);
diff --git a/generic/tkWindow.c b/generic/tkWindow.c
index 7afb031..0c60321 100644
--- a/generic/tkWindow.c
+++ b/generic/tkWindow.c
@@ -2351,6 +2351,9 @@ Tk_IdToWindow(
break;
}
}
+ if (window == None) {
+ return NULL;
+ }
hPtr = Tcl_FindHashEntry(&dispPtr->winTable, (char *) window);
if (hPtr == NULL) {