Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Sep 2009 17:41:50 +0200
From:      volker@vwsoft.com
To:        Eugene Grosbein <eugen@kuzbass.ru>
Cc:        Doug Barton <dougb@FreeBSD.org>, net@freebsd.org
Subject:   Re: host(1) coredumps
Message-ID:  <4AAD12BE.1090600@vwsoft.com>
In-Reply-To: <20090913042742.GA32897@svzserv.kemerovo.su>
References:  <20090913042742.GA32897@svzserv.kemerovo.su>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------040800050003010101050006
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

On 09/13/09 06:27, Eugene Grosbein wrote:
> Hi!
> 
> For 8.0-BETA3:
> 
> % host -l grosbein.pp.ru. ns2.rucable.net.
> ; Transfer failed.
> /usr/local/src/lib/bind/isc/../../../contrib/bind9/lib/isc/unix/socket.c:2486:
> REQUIRE((((sock) != ((void *)0)) && (((const isc__magic_t *)(sock))->magic
> == ((('I') << 24 | ('O') << 16 | ('i') << 8 | ('o')))))) failed.
> zsh: abort (core dumped)  host -l grosbein.pp.ru. ns2.rucable.net.
> 
> Shoud I send PR?
> 
> Eugene Grosbein

Eugene,

the attached patch works around the error for me. As this is contributed
code, it should be fixed upstream (no need to file a PR).

Volker


--------------040800050003010101050006
Content-Type: text/plain;
 name="dighost.c.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="dighost.c.diff"

--- contrib/bind9/bin/dig/dighost.c.orig	2009-09-13 14:24:13.000000000 +0000
+++ contrib/bind9/bin/dig/dighost.c	2009-09-13 14:31:52.000000000 +0000
@@ -2604,11 +2604,13 @@
 
 	if (sevent->result == ISC_R_CANCELED) {
 		debug("in cancel handler");
-		isc_socket_detach(&query->sock);
-		sockcount--;
-		INSIST(sockcount >= 0);
-		debug("sockcount=%d", sockcount);
-		query->waiting_connect = ISC_FALSE;
+		if (query->sock != NULL) {
+			isc_socket_detach(&query->sock);
+			sockcount--;
+			INSIST(sockcount >= 0);
+			debug("sockcount=%d", sockcount);
+			query->waiting_connect = ISC_FALSE;
+		}
 		isc_event_free(&event);
 		l = query->lookup;
 		clear_query(query);

--------------040800050003010101050006--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4AAD12BE.1090600>