Don't call conn.logout if conn.connect failed

Here's the fix for the IMAP crashers @dizzyd :)