mirror of
https://github.com/nginx/nginx.git
synced 2025-01-06 07:27:47 +08:00
fix ngx_http_perl_sleep_handler()
This commit is contained in:
parent
65b8a197b9
commit
df88a81783
@ -273,10 +273,22 @@ ngx_http_perl_handle_request(ngx_http_request_t *r)
|
|||||||
static void
|
static void
|
||||||
ngx_http_perl_sleep_handler(ngx_http_request_t *r)
|
ngx_http_perl_sleep_handler(ngx_http_request_t *r)
|
||||||
{
|
{
|
||||||
|
ngx_event_t *wev;
|
||||||
|
|
||||||
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
|
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
|
||||||
"perl sleep handler");
|
"perl sleep handler");
|
||||||
|
|
||||||
ngx_http_perl_handle_request(r);
|
wev = r->connection->write;
|
||||||
|
|
||||||
|
if (wev->timedout) {
|
||||||
|
wev->timedout = 0;
|
||||||
|
ngx_http_perl_handle_request(r);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ngx_handle_write_event(wev, 0) == NGX_ERROR) {
|
||||||
|
ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user