From: Operating system: PHP version: 5.4.0RC4 Package: Session related Bug Type: Bug Bug description:Invalid return values
Description: ------------ According to the documentation at http://www.php.net/manual/en/class.sessionhandler.php the various methods return 0 for success and 1 for failure which is kind of backwards since 0 would normally be evaluated as false and 1 as true. This is in direct contradiction with the current expected behaviour of session_set_save_handler() http://www.php.net/manual/en/function.session-set-save-handler.php which expects true or false return values except for the read handler which should always return a string. What's the deal here? I think the return values really should be true and false for this class, as expected by session_set_save_handler() Expected result: ---------------- I would expect the methods of SessionHandler class to return back true or false for all methods except read() which should return a string, as expected by the session_set_save_handler() -- Edit bug report at https://bugs.php.net/bug.php?id=60640&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=60640&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=60640&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=60640&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=60640&r=fixed Fixed in SVN and need be documented: https://bugs.php.net/fix.php?id=60640&r=needdocs Fixed in release: https://bugs.php.net/fix.php?id=60640&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=60640&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=60640&r=needscript Try newer version: https://bugs.php.net/fix.php?id=60640&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=60640&r=support Expected behavior: https://bugs.php.net/fix.php?id=60640&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=60640&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=60640&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=60640&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=60640&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=60640&r=dst IIS Stability: https://bugs.php.net/fix.php?id=60640&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=60640&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=60640&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=60640&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=60640&r=mysqlcfg