[nginx] Resolver: fixed possible segmentation fault on DNS forma...
Maxim Dounin
mdounin at mdounin.ru
Tue Jan 26 16:27:34 UTC 2016
details: http://hg.nginx.org/nginx/rev/c36482d0a79f
branches: stable-1.8
changeset: 6355:c36482d0a79f
user: Roman Arutyunyan <arut at nginx.com>
date: Tue Jan 26 16:46:18 2016 +0300
description:
Resolver: fixed possible segmentation fault on DNS format error.
diffstat:
src/core/ngx_resolver.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff --git a/src/core/ngx_resolver.c b/src/core/ngx_resolver.c
--- a/src/core/ngx_resolver.c
+++ b/src/core/ngx_resolver.c
@@ -1292,7 +1292,7 @@ ngx_resolver_process_response(ngx_resolv
times = 0;
for (q = ngx_queue_head(&r->name_resend_queue);
- q != ngx_queue_sentinel(&r->name_resend_queue) || times++ < 100;
+ q != ngx_queue_sentinel(&r->name_resend_queue) && times++ < 100;
q = ngx_queue_next(q))
{
rn = ngx_queue_data(q, ngx_resolver_node_t, queue);
More information about the nginx-devel
mailing list