Edit report at https://bugs.php.net/bug.php?id=70871&edit=1
ID: 70871
Updated by: yohgaki@php.net
Reported by: jacky at xsteach dot com
Summary: session_regenerate_id(): Failed to create session
ID: user (path: )
Status: Assigned
Type: Bug
Package: Session related
Operating System: mac os x
PHP Version: 7.0.0RC6
Assigned To: yohgaki
Block user comment: N
Private report: N
New Comment:
@narf
OK. Could tell me where I can look at the save handler code?
Previous Comments:
------------------------------------------------------------------------
[2015-11-12 18:00:05] narf at devilix dot net
@yasuo
I didn't say that session_start() issues that message.
What I'm saying is that calling session_regenerate_id() *immediately after* session_start(),
would issue this:
session_regenerate_id(): Failed to create session ID: user (path: <value of
session.save_path>)
And I'm kind of proxy-ing a bug report that was submitted to me here: https://github.com/bcit-ci/CodeIgniter/issues/4230
------------------------------------------------------------------------
[2015-11-12 02:19:48] yohgaki@php.net
@narf
session_start() should never raise error like
Warning: session_regenerate_id(): Cannot regenerate session id - session is not active in - on line
4
If you think it's not your save handler's problem, please file a new bug report with your
save handler code.
Recent (5.6 and up, IIRC) has stricter specification for save handlers. Refer to
https://bugs.php.net/bug.php?id=70520
even example save handler in the manual was wrong.
------------------------------------------------------------------------
[2015-11-10 18:10:58] narf at devilix dot net
With a custom session handler, it also spits out the same error message *immediately after* a
session_start() call - at that point, the session is not inactive.
Also, this is a breaking change and should not happen at the RC stage.
------------------------------------------------------------------------
[2015-11-10 01:55:09] yohgaki@php.net
@laruence
Yes. Session becames inactive by calling session_destroy(). Therefore, session_regenerate_id()
complains about bogus call as it requires active session to be useful.
------------------------------------------------------------------------
[2015-11-08 07:24:26] bellosthomas at gmail dot com
Similar problem here
I have a custom session handler storing session in memcache
However, when I invoke session_regenerate_id(true), I get a fatal error
Catchable fatal error: session_regenerate_id(): Failed to create session ID: user
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=70871
--
Edit this bug report at https://bugs.php.net/bug.php?id=70871&edit=1