]> git.kaiwu.me - nginx.git/commit
SPDY: fixed off_t/size_t type conversions on 32 bits platforms.
authorValentin Bartenev <vbart@nginx.com>
Wed, 15 Jan 2014 09:23:31 +0000 (13:23 +0400)
committerValentin Bartenev <vbart@nginx.com>
Wed, 15 Jan 2014 09:23:31 +0000 (13:23 +0400)
commitd143119e3cb939b69cb77d5bce6ac37f16e7c197
treedb861c047582d70114a1ab840e88fbff44aef0b1
parent70c010167f7f65e7b7a1f936cbf125baaf84fb7f
SPDY: fixed off_t/size_t type conversions on 32 bits platforms.

Parameters of ngx_http_spdy_filter_get_shadow() are changed from size_t to off_t
since the last call of the function may get size and offset from the rest of a
file buffer.  This fixes possible data loss rightfully complained by MSVC on 32
bits systems where off_t is 8 bytes long while size_t is only 4 bytes.

The other two type casts are needed just to suppress warnings about possible
data loss also complained by MSVC but false positive in these cases.
src/http/ngx_http_spdy_filter_module.c