|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2001-06-09 01:11 UTC] sniper@php.net
[2001-06-09 08:23 UTC] alex at gai dot ru
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Nov 07 00:00:02 2025 UTC |
===cut=== <?php function open ($save_path, $session_name) { $f = fopen('log', 'a'); fputs($f, "open ($save_path, $session_name)\n"); fclose($f); return true; } function close() { $f = fopen('log', 'a'); fputs($f, "close\n"); fclose($f); return true; } function read ($key) { $f = fopen('log', 'a'); fputs($f, "read ($key)\n"); fclose($f); return "foo|i:1;"; } function write ($key, $val) { $ip = getenv("REMOTE_ADDR"); $f = fopen('log', 'a'); fputs($f, "write ($key, $val)\n"); fclose($f); return true; } function destroy ($key) { $f = fopen('log', 'a'); fputs($f, "destroy($key)\n"); fclose($f); return true; } function gc ($maxlifetime) { return true; } session_set_save_handler ("open", "close", "read", "write", "destroy", "gc"); session_start(); $foo++; ?> ===cut=== this will produce only one "log" only with "open" and "read", no "write" and "close"... this is not only 4.0.5 bug, but 4.0.4pl1 too.