Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#1592 if embedded windows used, exit command causes a crash

obsolete: 8.4.4
closed
Chengye Mao
5
2004-12-17
2003-10-28
Paul Shabash
No

If I create any embedded windows in wish 8.4.4 (using
the toplevel's -container and -use options), issuing the
command "exit" will cause wish to pop the error
message "TkGetOtherWindow couldn't find window" and
then to crash.

For example, sourcing the following script will crash wish
8.4.4:

set parent [ toplevel .parent -container 1 ];

set embedded [ toplevel .embedded -use [ winfo id
$parent ] ];

exit;

The problem seems to occur because the embedded
windows list is not cleared properly. File
win/tkWinEmbed.c:

ThreadSpecificData *tsdPtr = (ThreadSpecificData *)
Tcl_GetThreadData(&dataKey, sizeof
(ThreadSpecificData));

tsdPtr->firstContainerPtr

etc.

Discussion

  • Chengye Mao
    Chengye Mao
    2004-12-17

    • status: open --> closed
     
  • Chengye Mao
    Chengye Mao
    2004-12-17

    Logged In: YES
    user_id=191079

    This was due to an improper sequence of exit handler
    invoking during finalization. CleanupContainerList should be
    invoked after DeleteWindowsExitProc to avoid panics and
    potential crashes.