-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't change the default session_handler if it is allready set Ref: #5127 #5142
Conversation
tested by @Olvikolvi at #5127 |
found old one #2695, that can be closed after current will be merged |
$handler = ini_get('session.save_handler'); | ||
|
||
// Set session.save_handler to files only if nothing else is set | ||
if ($handler = '') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks like here the mistake,
by call if ($handler = '')
you reset $handler
variable to empty value, so it always false
I think just enough if(!ini_get('session.save_handler'))
@zero-24 still small mistake ;) also I just thought, maybe also can remove this construction, as default PHP 'session.save_handler' is 'files' |
done @Fedik |
@zero-24 thanks! test |
Based on testing and a other PR that is tested and that whant to add the same code we can move this to RTC. Thanks for testing here @Fedik and @Olvikolvi ! This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5142. |
👍 |
Merged. Thanks! |
Steps to reproduce the issue
We are using memcache as default session handler and this set up is in php.ini.
Expected result
Joomla to use default session handler is not set in configuration.
Actual result
PHP Warning: session_start(): open(tcp://127.0.0.1:11211/sess_r5c5940ecaru55pr69bssctmu2, O_RDWR) failed: No such file or directory
System information (as much as possible)
php.ini: session.save_handler = memcache
Additional comments
Change libraries/joomla/session/storage/none.php to use default php session handler.
See: #5127 by @Olvikolvi