summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandi <andi@splitbrain.org>2005-07-01 13:21:48 +0200
committerandi <andi@splitbrain.org>2005-07-01 13:21:48 +0200
commit37065e654096bbf1a82d3bd11d990592b4d4b174 (patch)
tree5764975ab17f79f9e1bff357911614279ab809e0
parent6258cd9d2bd8824786e5485a93d483a1910a2dc4 (diff)
downloadrpg-37065e654096bbf1a82d3bd11d990592b4d4b174.tar.gz
rpg-37065e654096bbf1a82d3bd11d990592b4d4b174.tar.bz2
bugfix for weird ZendOptimizer bug #377 #378
darcs-hash:20050701112148-9977f-1d4a3a68ec7a1972c34104b3b988d849f412ae70.gz
-rw-r--r--inc/auth.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/inc/auth.php b/inc/auth.php
index c86bd3b49..e0f955568 100644
--- a/inc/auth.php
+++ b/inc/auth.php
@@ -178,10 +178,15 @@ function auth_cookiesalt(){
function auth_logoff(){
global $conf;
global $USERINFO;
- unset($_SESSION[$conf['title']]['auth']['user']);
- unset($_SESSION[$conf['title']]['auth']['pass']);
- unset($_SESSION[$conf['title']]['auth']['info']);
- unset($_SERVER['REMOTE_USER']);
+
+ if(isset($_SESSION[$conf['title']]['auth']['user']))
+ unset($_SESSION[$conf['title']]['auth']['user']);
+ if(isset($_SESSION[$conf['title']]['auth']['pass']))
+ unset($_SESSION[$conf['title']]['auth']['pass']);
+ if(isset($_SESSION[$conf['title']]['auth']['info']))
+ unset($_SESSION[$conf['title']]['auth']['info']);
+ if(isset($_SERVER['REMOTE_USER']))
+ unset($_SERVER['REMOTE_USER']);
$USERINFO=null; //FIXME
setcookie(DOKU_COOKIE,'',time()-600000,'/');
}