diff src/core/ngx_resolver.c @ 2487:9b4dce95c744

fix return code, this fixes segfault when two or more simultaneous connections are resolving the same address
author Igor Sysoev <igor@sysoev.ru>
date Sat, 31 Jan 2009 20:33:01 +0000
parents 8de5dc3e7001
children 1c87647b7ca5
line wrap: on
line diff
--- a/src/core/ngx_resolver.c
+++ b/src/core/ngx_resolver.c
@@ -626,7 +626,9 @@ ngx_resolve_addr(ngx_resolver_ctx_t *ctx
             ctx->next = rn->waiting;
             rn->waiting = ctx;
 
-            return NGX_AGAIN;
+            /* unlock addr mutex */
+
+            return NGX_OK;
         }
 
         ngx_queue_remove(&rn->queue);