php-src/ext/session
Sara Golemon 2d9885c8cb Fix handling of session user module custom handlers.
According to the documentation, returning TRUE from
user based session handlers should indicate success,
while returning FALSE should indicate failure.

The existing logic relied on casting the return value
to an integer and returning that from the function.
However, the internal handlers use SUCCESS/FAILURE
where SUCCESS == 0, and FAILURE == -1, so the following
behavior map occurs:

  return false; => return 0; => return SUCCESS
  return true; => return 1; => return <undefined>

Since the session API checks against FAILURE,
both boolean responses wind up appearing like "not FAILURE".

This diff reasserts boolean responses to behave as
documented and introduces some special handling
for integer responses of 0 and -1 so that code can be
written for older and newer versions of PHP.
2014-07-06 09:40:35 -07:00
..
tests Merge branch 'PHP-5.6' 2014-05-07 00:39:57 +02:00
config.m4 Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) 2011-09-13 22:28:15 +00:00
config.w32 Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) 2011-09-13 22:28:15 +00:00
CREDITS
mod_files.bat MFH 2008-12-30 19:37:35 +00:00
mod_files.c Merge branch 'PHP-5.4' into PHP-5.5 2014-04-14 23:30:14 +02:00
mod_files.h Bump year 2014-01-03 11:08:10 +08:00
mod_files.sh Fixed bug #49175: mod_files.sh does not support hash bits 2013-06-29 11:35:55 +09:00
mod_mm.c Fixed session module is sending multiple set-cookie headers when session.use_strict_mode=1 2014-01-15 11:06:06 +09:00
mod_mm.h Bump year 2014-01-03 11:08:10 +08:00
mod_user_class.c Bump year 2014-01-03 11:08:10 +08:00
mod_user.c Fix handling of session user module custom handlers. 2014-07-06 09:40:35 -07:00
mod_user.h Bump year 2014-01-03 11:08:10 +08:00
package.xml Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) 2011-09-13 22:28:15 +00:00
php_session.h Bump year 2014-01-03 11:08:10 +08:00
session.c Merge branch 'httponly-cookies' of https://github.com/mj/php-src 2014-06-12 10:03:14 +01:00