Stephen J. Turnbull wrote:
Glynn> Nickolay Pakoulin wrote:
>> XEmacs 21.4-14 hangs when editres client asks 'Select widget in
>> client'. XEmacs 21.5 does not hang.
>> XEmacs prints in the console:
>> xemacs: X Error of failed request: BadWindow (invalid Window
>> parameter)
Glynn> I get the same result here (BadWindow error for
Glynn> X_GetWindowAttributes, XEmacs hangs).
Now this is interesting. Glynn, so you think there's a chance that
this is a repeatable instance of whatever it is that causes the
intermittent BadWindow bugs we see?
My suspicion is that there is a problem with error handling.
E.g. in this instance, XGetWindowAttributes never returns. It's
blocking in _XReply(), presumably waiting for the X server to send it
the window's attributes. But XGetWindowAttributes() does appear to
allow for _XReply() failing, and _XReply() handles X_Error packets.
What options do we have? Our own error handler?
We already have that. The default X error handler just prints the
message then calls exit(). Ours doesn't do appear to do much more, but
it uses stderr_out, and I'm wondering if that is doing something
illegal (e.g. inadvertantly calling X functions).
Can we force the
widget to be realized and just not map/manage it?
Probably.
But it would be useful to get to the bottom of the general
error-handling problems.
--
Glynn Clements <glynn.clements(a)virgin.net>