git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [BUG] deamon.c does not compile when NO_IPV6 is used

From
Junio C Hamano <gitster@pobox.com>
Date
May 5, 2015, 17:55 UTC
Message-ID
<xmqqioc6ewnw.fsf@gitster.dls.corp.google.com>
In-Reply-To
<CAK4aQQJ9yT8+Q9jPQ78cauhyPj3j5WmpgrQJ5=cA-ECjaWn8BQ@mail.gmail.com>
Eduardo Espejo <eduardo.espejo@gmail.com> writes:
> Tested in 2.4 commit 3d4a3ffe64:
>
> daemon.c:636:24: error: use of undeclared identifier 'hostname'
>                 hent = gethostbyname(hostname.buf);

Thanks. It seems nobody actively interested in developing Git builds with NO_IPV6 these days?

Does this help?
 daemon.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/daemon.c b/daemon.c
index ac2bc85..d3d3e43 100644
--- a/daemon.c
+++ b/daemon.c
@@ -633,7 +633,7 @@ static void lookup_hostname(struct hostinfo *hi)
 		char **ap;
 		static char addrbuf[HOST_NAME_MAX + 1];
 
-		hent = gethostbyname(hostname.buf);
+		hent = gethostbyname(hi->hostname.buf);
 		if (hent) {
 			ap = hent->h_addr_list;
 			memset(&sa, 0, sizeof sa);
Previous: Eduardo EspejoNext: Junio C Hamano
Message 2 of 4 in “[BUG] deamon.c does not compile when NO_IPV6 is used”
  1. Eduardo EspejoMay 5, 2015
  2. Junio C HamanoMay 5, 2015
  3. daemon: unbreak NO_IPV6 build regressionJunio C Hamano, May 5, 2015
  4. René ScharfeMay 18, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.