ID: 14542
Updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Open
Bug Type: Unknown/Other Function
Operating System: Solaris 7
PHP Version: 4.1.0
New Comment:
The cause of the bug is that the following code is commented out in the
timeout handler (zend_timeout() in zend_execute_API):
/* is there any point in this? we're terminating the request
anyway...
PG(connection_status) |= PHP_CONNECTION_TIMEOUT;
*/
In our case, we need this error status to be set correctly. We want to
be able to detect the error when a script is terminated due to timeout.
Previous Comments:
------------------------------------------------------------------------
[2001-12-16 02:22:59] [EMAIL PROTECTED]
It seems that when a script terminates due to a
timeout connection_status() returns 0 (and
connection_timeout() no longer exists).
When aborted by a user connection_status() does return 1.
Sample script:
<?PHP
set_time_limit(1);
register_shutdown_function("shutdown");
function shutdown(){
$status = connection_status();
$err = "Connection status ($status).\n";
error_log($err, 3, "/tmp/phpstatus.log");
}
while(true){
echo ".";
}
?>
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=14542&edit=1