]> asedeno.scripts.mit.edu Git - PuTTY.git/commit
Better handling of outstanding CHANNEL_REQUESTS on channel destruction.
authorBen Harris <bjh21@bjh21.me.uk>
Sat, 25 Aug 2012 21:06:48 +0000 (21:06 +0000)
committerBen Harris <bjh21@bjh21.me.uk>
Sat, 25 Aug 2012 21:06:48 +0000 (21:06 +0000)
commit3d466aec90909db75eef8b6aaeedcd56eb925a2a
tree29a3e46f94ef7af5ff9561cb84e47d01963014b3
parent4e623f5b23ec549a3da21f9d819c8ee31fd31417
Better handling of outstanding CHANNEL_REQUESTS on channel destruction.

Part the first: make sure that all structures describing channel
requests are freed when the SSH connection is freed.  This involves
adding a means to ask a response handler to free any memory it holds.

Part the second: in ssh_channel_try_eof(), call
ssh2_channel_check_close() rather than emitting an SSH_MSG_CHANNEL_EOF
directly.  This avoids the possibility of closing the channel while a
CHANNEL_REQUEST is outstanding.

Also add some assertions that helped with tracking down the latter
problem.

[originally from svn r9623]
ssh.c