Win32: suppressed warnings by "-Werror=sign-compare".

This commit is contained in:
Kouhei Sutou 2014-10-11 21:09:29 +09:00
parent 3df66a632a
commit 8ae7751878

View File

@ -34,7 +34,7 @@ ngx_wsasend_chain(ngx_connection_t *c, ngx_chain_t *in, off_t limit)
/* the maximum limit size is the maximum u_long value - the page size */ /* the maximum limit size is the maximum u_long value - the page size */
if (limit == 0 || limit > NGX_MAX_UINT32_VALUE - ngx_pagesize) { if (limit == 0 || limit > (off_t) (NGX_MAX_UINT32_VALUE - ngx_pagesize)) {
limit = NGX_MAX_UINT32_VALUE - ngx_pagesize; limit = NGX_MAX_UINT32_VALUE - ngx_pagesize;
} }
@ -156,7 +156,7 @@ ngx_overlapped_wsasend_chain(ngx_connection_t *c, ngx_chain_t *in, off_t limit)
/* the maximum limit size is the maximum u_long value - the page size */ /* the maximum limit size is the maximum u_long value - the page size */
if (limit == 0 || limit > NGX_MAX_UINT32_VALUE - ngx_pagesize) { if (limit == 0 || limit > (off_t) (NGX_MAX_UINT32_VALUE - ngx_pagesize)) {
limit = NGX_MAX_UINT32_VALUE - ngx_pagesize; limit = NGX_MAX_UINT32_VALUE - ngx_pagesize;
} }