aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorValentin Bartenev <vbart@nginx.com>2014-09-16 21:12:51 +0400
committerValentin Bartenev <vbart@nginx.com>2014-09-16 21:12:51 +0400
commita7798de9bd8f1f4fd5bce6d77631073d472bed8a (patch)
tree4583d0e093d3ef3964f52e189f7ad368ab4de3c8 /src
parent681f74a9ba105ec074a9c8a63665193ce52f4068 (diff)
downloadnginx-a7798de9bd8f1f4fd5bce6d77631073d472bed8a.tar.gz
nginx-a7798de9bd8f1f4fd5bce6d77631073d472bed8a.zip
Limit req: don't truncate key value to 255 bytes.
While the module allows to use values up to 65535 bytes as a key, that actually never worked properly.
Diffstat (limited to 'src')
-rw-r--r--src/http/modules/ngx_http_limit_req_module.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/modules/ngx_http_limit_req_module.c b/src/http/modules/ngx_http_limit_req_module.c
index 74f7fdaa7..27d7b3092 100644
--- a/src/http/modules/ngx_http_limit_req_module.c
+++ b/src/http/modules/ngx_http_limit_req_module.c
@@ -461,7 +461,7 @@ ngx_http_limit_req_lookup(ngx_http_limit_req_limit_t *limit, ngx_uint_t hash,
lr = (ngx_http_limit_req_node_t *) &node->color;
- lr->len = (u_char) len;
+ lr->len = (u_short) len;
lr->excess = 0;
ngx_memcpy(lr->data, data, len);