Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

BUG: Fix for Cookie expiry timeout being passed as a large number on …

…64 bit machines
  • Loading branch information...
commit dff5447cbc672d4ad93cbce7580a65b4932eb72d 1 parent a4189a6
@kmayo-ss kmayo-ss authored
Showing with 6 additions and 3 deletions.
  1. +6 −3 control/Session.php
View
9 control/Session.php
@@ -523,9 +523,11 @@ public static function start($sid = null) {
if(!session_id() && !headers_sent()) {
if($domain) {
- session_set_cookie_params($timeout, $path, $domain, $secure /* secure */, true /* httponly */);
+ session_set_cookie_params($timeout, $path, $domain,
+ $secure /* secure */, true /* httponly */);
} else {
- session_set_cookie_params($timeout, $path, null, $secure /* secure */, true /* httponly */);
+ session_set_cookie_params($timeout, $path, null,
+ $secure /* secure */, true /* httponly */);
}
// Allow storing the session in a non standard location
@@ -541,7 +543,8 @@ public static function start($sid = null) {
// Modify the timeout behaviour so it's the *inactive* time before the session expires.
// By default it's the total session lifetime
if($timeout && !headers_sent()) {
- Cookie::set(session_name(), session_id(), time()+$timeout, $path, $domain ? $domain : null, $secure, true);
+ Cookie::set(session_name(), session_id(), $timeout/86400, $path, $domain ? $domain
+ : null, $secure, true);
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.