diff options
author | alecpl <alec@alec.pl> | 2011-11-15 10:50:30 +0000 |
---|---|---|
committer | alecpl <alec@alec.pl> | 2011-11-15 10:50:30 +0000 |
commit | 3fec6952ddbff1b5b487ea2927928338f39e4fef (patch) | |
tree | c684fe925e092fd78e1a2048eab4357bce7aacee /program/include/rcmail.php | |
parent | ecfaed571b2c38f4bcc2b6a0fa39fba15a5126ce (diff) |
- Applied fixes from trunk up to r5425
Diffstat (limited to 'program/include/rcmail.php')
-rw-r--r-- | program/include/rcmail.php | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/program/include/rcmail.php b/program/include/rcmail.php index 969e101f7..e06594fcd 100644 --- a/program/include/rcmail.php +++ b/program/include/rcmail.php @@ -678,18 +678,21 @@ class rcmail if (session_id()) return; + $sess_name = $this->config->get('session_name'); + $sess_domain = $this->config->get('session_domain'); + $lifetime = $this->config->get('session_lifetime', 0) * 60; + // set session domain - if ($domain = $this->config->get('session_domain')) { - ini_set('session.cookie_domain', $domain); + if ($sess_domain) { + ini_set('session.cookie_domain', $sess_domain); } // set session garbage collecting time according to session_lifetime - $lifetime = $this->config->get('session_lifetime', 0) * 60; if ($lifetime) { ini_set('session.gc_maxlifetime', $lifetime * 2); } ini_set('session.cookie_secure', rcube_https_check()); - ini_set('session.name', 'roundcube_sessid'); + ini_set('session.name', $sess_name ? $sess_name : 'roundcube_sessid'); ini_set('session.use_cookies', 1); ini_set('session.use_only_cookies', 1); ini_set('session.serialize_handler', 'php'); |