mirror of
https://github.com/nginx/nginx.git
synced 2024-12-18 23:57:49 +08:00
Merge of r4018:
Fix buffer overrun under Windows.
This commit is contained in:
parent
8f8839f98d
commit
ee7216bfa6
@ -228,7 +228,8 @@ ngx_win32_rename_file(ngx_str_t *from, ngx_str_t *to, ngx_log_t *log)
|
|||||||
ngx_uint_t collision;
|
ngx_uint_t collision;
|
||||||
ngx_atomic_uint_t num;
|
ngx_atomic_uint_t num;
|
||||||
|
|
||||||
name = ngx_alloc(to->len + 1 + 10 + 1 + sizeof("DELETE"), log);
|
name = ngx_alloc(to->len + 1 + NGX_ATOMIC_T_LEN + 1 + sizeof("DELETE"),
|
||||||
|
log);
|
||||||
if (name == NULL) {
|
if (name == NULL) {
|
||||||
return NGX_ENOMEM;
|
return NGX_ENOMEM;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user