summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tkPlace.c2
-rw-r--r--tests/canvWind.test4
2 files changed, 3 insertions, 3 deletions
diff --git a/generic/tkPlace.c b/generic/tkPlace.c
index 108097c..3c47476 100644
--- a/generic/tkPlace.c
+++ b/generic/tkPlace.c
@@ -426,7 +426,7 @@ static void
FreeContent(
Content *contentPtr)
{
- if (contentPtr->flags & PARENT_RECONFIG_PENDING) {
+ if (contentPtr->containerPtr && (contentPtr->containerPtr->flags & PARENT_RECONFIG_PENDING)) {
Tcl_CancelIdleCall(RecomputePlacement, contentPtr);
}
Tk_FreeConfigOptions((char *) contentPtr, contentPtr->optionTable,
diff --git a/tests/canvWind.test b/tests/canvWind.test
index 9777427..750321e 100644
--- a/tests/canvWind.test
+++ b/tests/canvWind.test
@@ -139,7 +139,7 @@ test canvWind-1.4 {DisplayWinItem, windows off-screen horizontally} -setup {
destroy .t
} -result {{1 3} {1 -79} {0 -79} {1 255} {0 255}}
-test canvWind-2.1 {DisplayWinItem, window gets destroyed duing <Configure>} -setup {
+test canvWind-2.1 {DisplayWinItem, window gets destroyed during <Configure>} -setup {
destroy .t
} -body {
toplevel .t
@@ -149,7 +149,7 @@ test canvWind-2.1 {DisplayWinItem, window gets destroyed duing <Configure>} -set
set id [.t.c create window 50 50 -window .t.c.f]
update
bind .t.c.f <Configure> {destroy .t.c.f}
- .t.c coords $id 60 60 ; # crashes!
+ .t.c coords $id 60 60 ; # was crashing
update
} -cleanup {
destroy .t