Limit req: Remove unused struct element
Maxim Dounin
mdounin at mdounin.ru
Sat Oct 8 02:15:36 UTC 2016
Hello!
On Fri, Oct 07, 2016 at 05:51:49PM -0700, Robert Paprocki wrote:
> # HG changeset patch
> # User Robert Paprocki <robert at cryptobells.com>
> # Date 1475887216 25200
> # Fri Oct 07 17:40:16 2016 -0700
> # Node ID eb5109e432b6138d2a128fd3766be2dbb11974af
> # Parent 1606a817c1d48ed351f1dd7d9cb9c996e2c77b9a
> Limit req: Remove unused struct element
>
> dummy doesn't appear to be necessary for padding alignment,
> and is unused in this module.
>
> diff -r 1606a817c1d4 -r eb5109e432b6
> src/http/modules/ngx_http_limit_req_module.c
> --- a/src/http/modules/ngx_http_limit_req_module.c Fri Oct 07 16:59:14 2016
> +0300
> +++ b/src/http/modules/ngx_http_limit_req_module.c Fri Oct 07 17:40:16 2016
> -0700
> @@ -12,7 +12,6 @@
>
> typedef struct {
> u_char color;
> - u_char dummy;
> u_short len;
> ngx_queue_t queue;
> ngx_msec_t last;
While it is not stricly necessary, it corresponds to the "data"
field in the ngx_rbtree_node_t and it is better to have it
explicitly present to simplify understanding of the code.
--
Maxim Dounin
http://nginx.org/
More information about the nginx-devel
mailing list