mirror of
https://github.com/nginx/nginx.git
synced 2025-01-19 01:42:58 +08:00
Events: honor NGX_USE_GREEDY_EVENT when kqueue support is enabled.
Currently this flag is needed for epoll and rtsig, and though these methods usually present on different platforms than kqueue, nginx can be compiled to support all of them.
This commit is contained in:
parent
d10251030a
commit
615d558843
@ -136,7 +136,7 @@ ngx_readv_chain(ngx_connection_t *c, ngx_chain_t *chain)
|
||||
return n;
|
||||
}
|
||||
|
||||
if (n < size) {
|
||||
if (n < size && !(ngx_event_flags & NGX_USE_GREEDY_EVENT)) {
|
||||
rev->ready = 0;
|
||||
}
|
||||
|
||||
|
@ -87,7 +87,9 @@ ngx_unix_recv(ngx_connection_t *c, u_char *buf, size_t size)
|
||||
return n;
|
||||
}
|
||||
|
||||
if ((size_t) n < size) {
|
||||
if ((size_t) n < size
|
||||
&& !(ngx_event_flags & NGX_USE_GREEDY_EVENT))
|
||||
{
|
||||
rev->ready = 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user