=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/clientloop.c,v retrieving revision 1.210 retrieving revision 1.211 diff -u -r1.210 -r1.211 --- src/usr.bin/ssh/clientloop.c 2009/05/25 06:48:01 1.210 +++ src/usr.bin/ssh/clientloop.c 2009/05/27 06:33:39 1.211 @@ -1,4 +1,4 @@ -/* $OpenBSD: clientloop.c,v 1.210 2009/05/25 06:48:01 andreas Exp $ */ +/* $OpenBSD: clientloop.c,v 1.211 2009/05/27 06:33:39 andreas Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -1463,6 +1463,12 @@ /* Stop watching for window change. */ signal(SIGWINCH, SIG_DFL); + + packet_start(SSH2_MSG_DISCONNECT); + packet_put_int(SSH2_DISCONNECT_BY_APPLICATION); + packet_put_cstring("disconnected by user"); + packet_send(); + packet_write_wait(); channel_free_all();