From 92786aebf1b8aa17612ebaf5dd0ee8cd4abf9616 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sat, 19 Sep 2009 08:23:03 -0700 Subject: s4-resolve: fixed a crash bug on timeout We were creating the name resolution context as a child of lp_ctx, which meant when we gave up on a connection the timer on name resolution kept running, and when it timed out the callback crashed as the socket was already removed. --- source4/nbt_server/wins/wins_dns_proxy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4/nbt_server') diff --git a/source4/nbt_server/wins/wins_dns_proxy.c b/source4/nbt_server/wins/wins_dns_proxy.c index cd605907a8..4ebfc05fd7 100644 --- a/source4/nbt_server/wins/wins_dns_proxy.c +++ b/source4/nbt_server/wins/wins_dns_proxy.c @@ -87,7 +87,7 @@ void nbtd_wins_dns_proxy_query(struct nbt_name_socket *nbtsock, if (resolve_ctx == NULL) goto failed; resolve_context_add_host_method(resolve_ctx); - creq = resolve_name_send(resolve_ctx, name, iface->nbtsrv->task->event_ctx); + creq = resolve_name_send(resolve_ctx, s, name, iface->nbtsrv->task->event_ctx); if (!creq) goto failed; creq->async.fn = nbtd_wins_dns_proxy_handler; -- cgit