diff options
author | Ruslan Ermilov <ru@nginx.com> | 2014-11-20 15:24:42 +0300 |
---|---|---|
committer | Ruslan Ermilov <ru@nginx.com> | 2014-11-20 15:24:42 +0300 |
commit | ef563debf1f0a3c15bde6ca645af646ad38d66cf (patch) | |
tree | 8ad92e25c1c613854eb20680bbcd6e9480fe4311 /src/core/ngx_resolver.h | |
parent | d4b7b74686cdfe7488214a210a95da0af0736f8e (diff) |
Resolver: fixed debug event logging.
In 954867a2f0a6, we switched to using resolver node as the timer event data.
This broke debug event logging.
Replaced now unused ngx_resolver_ctx_t.ident with ngx_resolver_node_t.ident
so that ngx_event_ident() extracts something sensible when accessing
ngx_resolver_node_t as ngx_connection_t.
Diffstat (limited to 'src/core/ngx_resolver.h')
-rw-r--r-- | src/core/ngx_resolver.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/core/ngx_resolver.h b/src/core/ngx_resolver.h index 264c8c42b..d3519fb6f 100644 --- a/src/core/ngx_resolver.h +++ b/src/core/ngx_resolver.h @@ -51,12 +51,16 @@ typedef void (*ngx_resolver_handler_pt)(ngx_resolver_ctx_t *ctx); typedef struct { - ngx_rbtree_node_t node; - ngx_queue_t queue; - /* PTR: resolved name, A: name to resolve */ u_char *name; + ngx_queue_t queue; + + /* event ident must be after 3 pointers as in ngx_connection_t */ + ngx_int_t ident; + + ngx_rbtree_node_t node; + #if (NGX_HAVE_INET6) /* PTR: IPv6 address to resolve (IPv4 address is in rbtree node key) */ struct in6_addr addr6; @@ -103,7 +107,7 @@ typedef struct { void *dummy; ngx_log_t *log; - /* ident must be after 3 pointers */ + /* event ident must be after 3 pointers as in ngx_connection_t */ ngx_int_t ident; /* simple round robin DNS peers balancer */ @@ -143,9 +147,6 @@ struct ngx_resolver_ctx_s { ngx_resolver_t *resolver; ngx_udp_connection_t *udp_connection; - /* ident must be after 3 pointers */ - ngx_int_t ident; - ngx_int_t state; ngx_str_t name; |