Fixing issue where Config.timeout wouldn't correctly countdown when many quick requests were sent.

This commit is contained in:
Mark Story 2010-05-11 00:39:10 -04:00
parent 05beaab272
commit 6e355312bb

View file

@ -614,8 +614,8 @@ class CakeSession extends Object {
$this->write('Config.time', $this->sessionTime);
if (Configure::read('Security.level') === 'high') {
$check = $this->read('Config.timeout');
$check = $check - 1;
$this->write('Config.timeout', Security::inactiveMins());
$check -= 1;
$this->write('Config.timeout', $check);
if (time() > ($time - (Security::inactiveMins() * Configure::read('Session.timeout')) + 2) || $check < 1) {
$this->renew();