GNOME Bugzilla – Bug 563354
gnome-session does not close ICE connection for qt3 apps
Last modified: 2009-01-06 01:44:52 UTC
Since gnome 2.24, eventually I cannot start any more sufficiently complex programs, when this happens gnome-session is using 100% CPU and the tty I ran startx from is filled with: _IceTransSocketUNIXAccept: accept() failed Running "uic -version" in a loop, the loop will stop after uic has been run almost 1000 times, when the bug is triggered. It seems that when a QT3 program is closed, including uic, IceCloseConnection() is called in gsm_xsmp_client_disconnect(), but it returns IceStartedShutdownNegotiation.
Created attachment 124009 [details] [review] Possibly fix, disable shutdown negotiation before close With this patch, the problem no longer occurs, but I have no idea if this is correct, or if actually QT3 needs to be fixed instead.
(In reply to comment #1) > Created an attachment (id=124009) [edit] > Possibly fix, disable shutdown negotiation before close > > With this patch, the problem no longer occurs, but I have no idea if this is > correct, or if actually QT3 needs to be fixed instead. From docs: When it is known that the client on the other side of the ICE connection has terminated the connection without initi- ating shutdown negotiation, the IceSetShutdownNegotiation function should be called to turn off shutdown negotiation. This will prevent IceCloseConnection from writing to a bro- ken connection. This seems to be exactly what's is happening here. The gsm_xsmp_client_disconnect() call only happens when the client is being finalized and the connection is known to be terminated. Hence, we should call IceStartedShutdownNegotiation() before IceCloseConnection(). This is a regression as previous gnome-session used to do that. Patch commited to gnome-2-24 branch and trunk.