IrcConnection: fix closing state