exit quietly with KeyboardInterrupt

if user presses ctrl+C while TCP server's running, nothing happens. with this patch it shuts down the server and exits.