C-c currently just calls `exit(1)`. This should be improved to cleanly close sockets, write to files and things.