Browse Source

git-daemon not listening when compiled with -DNO_IPV6

git-daemon was not listening when compiled with -DNO_IPV6.
socksetup() was not returning socket count when compiled with -DNO_IPV6.

Signed-off-by: Paul Serice <paul@serice.net>
Signed-off-by: Junio C Hamano <junkio@cox.net>
maint
Paul Serice 19 years ago committed by Junio C Hamano
parent
commit
f35230fb11
  1. 6
      daemon.c

6
daemon.c

@ -466,8 +466,14 @@ static int socksetup(int port, int **socklist_p) @@ -466,8 +466,14 @@ static int socksetup(int port, int **socklist_p)
return 0;
}

if (listen(sockfd, 5) < 0) {
close(sockfd);
return 0;
}

*socklist_p = xmalloc(sizeof(int));
**socklist_p = sockfd;
return 1;
}

#endif

Loading…
Cancel
Save