mirror of
https://github.com/nginx/nginx.git
synced 2026-10-21 19:41:35 +00: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
2 changed files with 4 additions and 2 deletions
|
|
@ -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…
Add table
Add a link
Reference in a new issue