Address several Valgrind errors

This allows ^D to terminate interactive mode.