From d5c472f16d5aa03b3f69dc1e985299cd53c2fb77 Mon Sep 17 00:00:00 2001 From: kink Date: Wed, 18 Aug 2004 20:16:46 +0000 Subject: [PATCH] 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 --- functions/imap_general.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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 +?> -- 2.25.1