Latest update - 7375
This commit is contained in:
@@ -2418,23 +2418,32 @@ ngx_http_file_cache_set_slot(ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
|
|||||||
|
|
||||||
p = (u_char *) ngx_strchr(name.data, ':');
|
p = (u_char *) ngx_strchr(name.data, ':');
|
||||||
|
|
||||||
if (p) {
|
if (p == NULL) {
|
||||||
name.len = p - name.data;
|
ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
|
||||||
|
"invalid keys zone size \"%V\"", &value[i]);
|
||||||
p++;
|
return NGX_CONF_ERROR;
|
||||||
|
|
||||||
s.len = value[i].data + value[i].len - p;
|
|
||||||
s.data = p;
|
|
||||||
|
|
||||||
size = ngx_parse_size(&s);
|
|
||||||
if (size > 8191) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
|
name.len = p - name.data;
|
||||||
"invalid keys zone size \"%V\"", &value[i]);
|
|
||||||
return NGX_CONF_ERROR;
|
s.data = p + 1;
|
||||||
|
s.len = value[i].data + value[i].len - s.data;
|
||||||
|
|
||||||
|
size = ngx_parse_size(&s);
|
||||||
|
|
||||||
|
if (size == NGX_ERROR) {
|
||||||
|
ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
|
||||||
|
"invalid keys zone size \"%V\"", &value[i]);
|
||||||
|
return NGX_CONF_ERROR;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (size < (ssize_t) (2 * ngx_pagesize)) {
|
||||||
|
ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
|
||||||
|
"keys zone \"%V\" is too small", &value[i]);
|
||||||
|
return NGX_CONF_ERROR;
|
||||||
|
}
|
||||||
|
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ngx_strncmp(value[i].data, "inactive=", 9) == 0) {
|
if (ngx_strncmp(value[i].data, "inactive=", 9) == 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user