-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Closed
Labels
0. Needs triagePending check for reproducibility or if it fits our roadmapPending check for reproducibility or if it fits our roadmap25-feedbackbug
Description
SessionInternal::clear() does strange things:
server/lib/private/Session/Internal.php
Lines 103 to 108 in f5d1365
| public function clear() { | |
| $this->invoke('session_unset'); | |
| $this->regenerateId(); | |
| $this->startSession(true); | |
| $_SESSION = []; | |
| } |
Error: session_start(): Ignoring session_start() because a session is already active at /var/www/localhost/htdocs/nextcloud-git/lib/private/Session/Internal.php#208
- session_unset() -- ok, destroys all values
- regenerateId() -- ok, generate a new session id
- start_session() -- oops. But the session is still open.
So either the start_session is superfluous and can be omitted -- at least in current versions of php -- or there is missing something like a session_destroy() (but then regenerate_id() could be omitted?) or a session_write_close() which would write the (now empty) session file to disk.
Metadata
Metadata
Assignees
Labels
0. Needs triagePending check for reproducibility or if it fits our roadmapPending check for reproducibility or if it fits our roadmap25-feedbackbug