Skip to content

Commit 067c229

Browse files
author
Tom Boutell
authored
Merge pull request #15 from pbowyer/patch-2
Prevent "Warning: ini_set(): A session is active. You cannot change t…
2 parents 5780400 + f4aa50f commit 067c229

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/user/sfBasicSecurityUser.class.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ public function initialize(sfEventDispatcher $dispatcher, sfStorage $storage, $o
252252
}
253253

254254
// force the max lifetime for session garbage collector to be greater than timeout
255-
if (ini_get('session.gc_maxlifetime') < $this->options['timeout'])
255+
if (session_status() !== PHP_SESSION_ACTIVE && ini_get('session.gc_maxlifetime') < $this->options['timeout'])
256256
{
257257
ini_set('session.gc_maxlifetime', $this->options['timeout']);
258258
}

0 commit comments

Comments
 (0)