<Ctrl-]>, then enter quit
The keys to exit properly are Ctrl-D. It's equivalent to "logout".
Ctrl+C just send Break signal to current shell
if you want to exit, just enter "Ctrl+]" then enter "quit"
note: it is better to logoff from server, then server send "fin"
and connection will closed..
I think you use a application connection
in your application used CTRL+C for any process
you can change that od unused that
in your server tarp for CTRL+C
you can type
trap " " SIGINT or trap " " 2