Handle and clean up irc_sessions on remote close/error.