Modified the session killer.
authorphilippe_mingo <philippe_mingo@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Fri, 19 Oct 2001 07:43:19 +0000 (07:43 +0000)
committerphilippe_mingo <philippe_mingo@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Fri, 19 Oct 2001 07:43:19 +0000 (07:43 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1586 7612ce4b-ef26-0410-bec9-ea0150e637f0

src/login.php

index 2b56300..c4e1db8 100644 (file)
    ereg ("(^.*/)[^/]+/[^/]+$", $PHP_SELF, $regs);
    $base_uri = $regs[1];
 
-   if ( session_id() <> '' ) {
-       session_destroy();
-       // In case the last session was not terminated properly, make sure
-       // we get a new one.
-       $cookie_params = session_get_cookie_params(); 
-       setcookie(session_name(),'',0,$cookie_params['path'].$cookie_params['domain']); 
-   }
+   @session_destroy();
+   // In case the last session was not terminated properly, make sure
+   // we get a new one.
+   $cookie_params = session_get_cookie_params(); 
+   setcookie(session_name(),'',0,$cookie_params['path'].$cookie_params['domain']); 
    setcookie('username', '', 0, $base_uri);
    setcookie('key', '', 0, $base_uri);
    header ('Pragma: no-cache');