From: kink Date: Wed, 18 Aug 2004 20:16:46 +0000 (+0000) Subject: Close connection cleanly when login/pw incorrect, following RFC recommendation. X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=commitdiff_plain;h=d5c472f16d5aa03b3f69dc1e985299cd53c2fb77 Close connection cleanly when login/pw incorrect, following RFC recommendation. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@7937 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/functions/imap_general.php b/functions/imap_general.php index 81673749..511161bf 100755 --- a/functions/imap_general.php +++ b/functions/imap_general.php @@ -721,6 +721,8 @@ function sqimap_login ($username, $password, $imap_server_address, $imap_port, $ set_up_language($squirrelmail_language, true); include_once(SM_PATH . 'functions/display_messages.php' ); sqsession_destroy(); + /* terminate the session nicely */ + sqimap_logout($imap_stream); logout_error( _("Unknown user or password incorrect.") ); exit; } @@ -988,4 +990,4 @@ function map_yp_alias($username) { return chop(substr($yp, strlen($username)+1)); } -?> \ No newline at end of file +?>