>>if I (as an IMAP client) have to exit quickly and have an open IMAP
 >>connection, I can't wait around for the IMAP server's responses.

 >>In this case, should I send LOGOUT and immediately close the TCP
 >>connection, or should I just close the TCP connection?  I can't quite make
 >>up my mind.

I find this a tough question to answer.  My inclination is just to close 
the connection but I cannot offer much justification for that.  One 
consideration is that, if you send a LOGOUT and then immediately close the 
connection, it seems likely that the server will never see the LOGOUT.

Seems to me that a more critical question in the circumstance is whether or 
not to send a CLOSE command if the session is in the selected state (so 
that expunging is performed).  But since you don't raise that question 
maybe you already dealt with it.

Pete


Reply via email to