Mailing List Archive

[Bug 1010] SSH sometimes hangs on exit when multiple forwarded X11 clients are closed
http://bugzilla.mindrot.org/show_bug.cgi?id=1010

Summary: SSH sometimes hangs on exit when multiple forwarded X11
clients are closed
Product: Portable OpenSSH
Version: 4.0p1
Platform: All
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: sshd
AssignedTo: openssh-bugs@mindrot.org
ReportedBy: t8m@centrum.cz


SSH sometimes hangs on exit when multiple forwarded X11 clients are closed.

This is not easy to reproduce however here are the steps which make it to
reproduce almost 100% for me:

1. ssh -Y host
2. xsm ; exit in the ssh session
3. for i in `seq 1 50` ; do (nice -20 xterm &) ; done in the xterm which was
started from xsm
4. after all the xterms are up and running shutdown immediately the xsm

Expected result:
ssh session ended normally

What really happens:
ssh session hangs

After looking at the debug log from the sshd it seems that some of the X11
channels are stuck waiting for output drain however it won't happen as the other
end - the xterm - already exited.



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
[Bug 1010] SSH sometimes hangs on exit when multiple forwarded X11 clients are closed [ In reply to ]
http://bugzilla.mindrot.org/show_bug.cgi?id=1010





------- Additional Comments From t8m@centrum.cz 2005-04-06 06:41 -------
Created an attachment (id=868)
--> (http://bugzilla.mindrot.org/attachment.cgi?id=868&action=view)
Proposed patch

This patch solves the problem for me however I'm not sure if it's completely
correct.




------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.