dgp Has something changed from Tk 8.4 -> Tk 8.5 when the [send] command is deleted?
dgp I have a "big wish" program.
dgp When I build it with Tcl/Tk 8.4.18, I can [rename send {}], and things work fine
dgp When I build with core-8-5-branch, and enter [rename send {}; exit] at the interactive prompt, I get an X error....
dgp $ ./omfsh
X Error of failed request: RenderBadPicture (invalid Picture parameter)
Major opcode of failed request: 155 (RENDER)
Minor opcode of failed request: 7 (RenderFreePicture)
Picture id in failed request: 0x260003f
Serial number of failed request: 1525
Current serial number in output stream: 1582
dgp look familiar to any Tk experts?
Logged In: YES
user_id=80530
Originator: YES
This appears to be the same issue:
http://objectmix.com/tcl/250971-bug-8-5b1.html
Logged In: YES
user_id=80530
Originator: YES
Haven't fully tracked it down yet, but
the saga of 1712081 is involved somehow.
Logged In: YES
user_id=80530
Originator: YES
Ok, now I think 1712081 has nothing to
do with it, so withdraw that claim first.
The trouble first arises with
Kevin Kenny's 2006-11-27 commit to
unix/configure(.in).
All that change really does, though, is
to change from a --disable-xft default
build to a --enable-xft default build
in my current test environment.
Sure enough if I force a --disable-xft
build of Tk 8.5-HEAD, and use that, the
problem goes away.
Logged In: YES
user_id=99768
Originator: NO
While I committed the change that makes --enable-xft the default, that was on the basis of (a) it's now nearly-universal in Linux distros, and (b) Tk looks like hell without it. Beyond those two factoids, I'm extremely ignorant of what goes on inside. (If it were the *non*-Xft build failing, I'd feel more competent to have a look.)
Referring to someone who might have a clue how to approach debugging this.
Logged In: YES
user_id=68433
Originator: NO
Duplicate of #1821174.
Cause of the problem: Tk's teardown sequence sets tsdPtr->displayList to NULL before calling TkpCloseDisplay on each member of the list, so if any X errors occur during the final XSync(), ErrorProc is not able to dispatch them to the correct TkErrorHandler.
The RenderBadPicture error is raised in response to XftDrawDestroy() when the Drawable associated with the XftDraw has been destroyed before the XftDraw itself is. This call (in FinishedWithFont, in tkUnixRFont.c) is bracketed by Tk_CreateErrorHandler / Tk_DeleteErrorHandler, so would not be a fatal error, except for the problem above.
Removing the [send] command causes (among other things) an XSync() to occur; this normally occurs at a point in Tk's teardown sequence where it happens to mask the above two problems. If the application removes [send] itself earlier, this doesn't happen, and the problem manifests.