diff options
author | Igor Sysoev <igor@sysoev.ru> | 2006-03-10 12:51:52 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2006-03-10 12:51:52 +0000 |
commit | 13c68741f29943d0ba45f7c9d5a5c4251d5f16f6 (patch) | |
tree | 539580ab05f906419ca310ab8e0d437a1ae7fec8 /src/event/modules/ngx_kqueue_module.c | |
parent | 15465ff78e5b53c9fb88dfde0adb8c99f6066892 (diff) | |
download | nginx-release-0.3.31.tar.gz nginx-release-0.3.31.zip |
nginx-0.3.31-RELEASE importrelease-0.3.31
*) Change: now nginx passes the malformed proxied backend responses.
*) Feature: the "listen" directives support the address in the "*:port"
form.
*) Feature: the EVFILER_TIMER support in MacOSX 10.4.
*) Workaround: for MacOSX 64-bit kernel kqueue millisecond timeout
bug.
Thanks to Andrei Nigmatulin.
*) Bugfix: if there were several "listen" directives listening one
various addresses inside one server, then server names like
"*.domain.tld" worked for first address only; the bug had appeared
in 0.3.18.
*) Bugfix: if the HTTPS protocol was used in the "proxy_pass" directive
and the request body was in temporarily file then the request was
not transferred.
*) Bugfix: perl 5.8.8 compatibility.
Diffstat (limited to 'src/event/modules/ngx_kqueue_module.c')
-rw-r--r-- | src/event/modules/ngx_kqueue_module.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/event/modules/ngx_kqueue_module.c b/src/event/modules/ngx_kqueue_module.c index 88b5b3fd5..f3ca737be 100644 --- a/src/event/modules/ngx_kqueue_module.c +++ b/src/event/modules/ngx_kqueue_module.c @@ -490,8 +490,17 @@ ngx_kqueue_process_events(ngx_cycle_t *cycle, ngx_msec_t timer, tp = NULL; } else { + + /* + * 64-bit MacOSX kernel has the bug: kernel level ts.tv_nsec is + * the int32_t while user level ts.tv_nsec is the long (64-bit), + * so on the big endian PowerPC all nanoseconds are lost. + * NGX_MACOSX_KEVENT_BUG_SHIFT on these machines is "<< 32". + */ + ts.tv_sec = timer / 1000; - ts.tv_nsec = (timer % 1000) * 1000000; + ts.tv_nsec = (long) ((timer % 1000) * 1000000) + NGX_MACOSX_KEVENT_BUG_SHIFT; tp = &ts; } |