mirror of
https://github.com/php/php-src.git
synced 2025-08-18 23:18:56 +02:00
Add/unify aborted connection handling
This commit is contained in:
parent
13183ed5c3
commit
27a8480028
4 changed files with 14 additions and 18 deletions
|
@ -126,7 +126,6 @@ static int sapi_apache_ub_write(const char *str, uint str_length)
|
|||
{
|
||||
int ret;
|
||||
SLS_FETCH();
|
||||
PLS_FETCH();
|
||||
|
||||
if (SG(server_context)) {
|
||||
ret = rwrite(str, str_length, (request_rec *) SG(server_context));
|
||||
|
@ -134,10 +133,7 @@ static int sapi_apache_ub_write(const char *str, uint str_length)
|
|||
ret = fwrite(str, 1, str_length, stderr);
|
||||
}
|
||||
if(ret != str_length) {
|
||||
PG(connection_status) = PHP_CONNECTION_ABORTED;
|
||||
if (!PG(ignore_user_abort)) {
|
||||
zend_bailout();
|
||||
}
|
||||
php_handle_aborted_connection();
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue