yii: session_regenerate_id(): Session object destruction failed
When I am trying to log-in after logging off, I getting such WARNING: D:\work\localhost\yii-1.1.13\framework\web\CHttpSession.php(185)
This WARNING appears randomly.
183 public function regenerateID($deleteOldSession=false)
184 {
185 session_regenerate_id($deleteOldSession);
186 }
If I add check to code:
183 public function regenerateID($deleteOldSession=false)
184 {
185 if (session_status() != PHP_SESSION_ACTIVE)
186 session_regenerate_id($deleteOldSession);
187 }
Then the problem (warning) disappears.
About this issue
- Original URL
- State: closed
- Created 11 years ago
- Comments: 17 (6 by maintainers)
Commits related to this issue
- Fix session_regenerate_id Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/2376 — committed to lukyer/http by lukyer 9 years ago
- Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/2376 — committed to lukyer/http by lukyer 9 years ago
- Fix session_regenerate_id Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/2376 — committed to lukyer/http by lukyer 9 years ago
- Fix session_regenerate_id Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/2376 Fix session_regenerate... — committed to lukyer/http by lukyer 9 years ago
- Fix session_regenerate_id Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/2376 — committed to lukyer/http by lukyer 9 years ago
- Fix session_regenerate_id Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/2376 — committed to lukyer/http by lukyer 9 years ago
- Session: session ID is not regenerated when not set Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/23... — committed to lukyer/http by lukyer 9 years ago
- Session: session ID is not regenerated when not set Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/23... — committed to nette/http by lukyer 9 years ago
- Session: session ID is not regenerated when not set Fixes `session_regenerate_id(): Session object destruction failed` which sometimes occures. See same fix: https://github.com/yiisoft/yii/issues/23... — committed to nette/http by lukyer 9 years ago
@samdark Yes, the problem has been solved by introducing own customized class:
and changing configuration:
The exception is no longer thrown. However, I have noticed a very strange behavior (again under IE only), after applying this fix. I’ll report in separate comment below, to not mix two things.