@ -45,6 +45,7 @@ abstract class rcube_session
protected $cookiename = 'roundcube_sessauth';
protected $cookiename = 'roundcube_sessauth';
protected $ip_check = false;
protected $ip_check = false;
protected $logging = false;
protected $logging = false;
protected $ignore_write = false;
/**
/**
@ -274,11 +275,16 @@ abstract class rcube_session
* Generate and set new session id
* Generate and set new session id
*
*
* @param boolean $destroy If enabled the current session will be destroyed
* @param boolean $destroy If enabled the current session will be destroyed
*
* @return bool
* @return bool
*/
*/
public function regenerate_id($destroy = true)
public function regenerate_id($destroy = true)
{
{
// Since PHP 7.0 session_regenerate_id() will cause the old
// session data update, we don't need this
$this->ignore_write = true;
session_regenerate_id($destroy);
session_regenerate_id($destroy);
$this->ignore_write = false;
$this->vars = null;
$this->vars = null;
$this->key = session_id();
$this->key = session_id();