summaryrefslogtreecommitdiff
path: root/include/sessions.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2017-07-13 14:40:30 +0300
committerAndrew Dolgov <[email protected]>2017-07-13 14:40:30 +0300
commit09628e1b1a71fb03933e7ff4d5eb9da7f83d5186 (patch)
tree792097f9376e650bdb5aa285dc04739eb1385078 /include/sessions.php
parente6d77d2b29e0b177bc5273fa90a99eacb1302b52 (diff)
rework previous 32 bit session stuff
Diffstat (limited to 'include/sessions.php')
-rw-r--r--include/sessions.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/sessions.php b/include/sessions.php
index adc973fe7..0690ab7ed 100644
--- a/include/sessions.php
+++ b/include/sessions.php
@@ -9,7 +9,7 @@
require_once "lib/gettext/gettext.inc";
require_once "version.php";
- $session_expire = max(SESSION_COOKIE_LIFETIME, 86400) & 0xFFFFFFFF; // clip to 32 bit
+ $session_expire = min(2147483647 - time() - 1, max(SESSION_COOKIE_LIFETIME, 86400));
$session_name = (!defined('TTRSS_SESSION_NAME')) ? "ttrss_sid" : TTRSS_SESSION_NAME;
if (@$_SERVER['HTTPS'] == "on") {