lists.arthurdejong.org
RSS feed

cvsd commit: MODIFIED: . ...

[Date Prev][Date Next] [Thread Prev][Thread Next]

cvsd commit: MODIFIED: . ...



User: arthur
Date: 10/08/25 23:24:54

Modified:    . cvsd.c
Log:
now always ignore EADDRINUSE for bind() calls because now IPv4 addresses from 
getaddrinfo() are returned before IPv6 ones for some reason


Revision  Changes    Path
1.118     +1 -3      cvsd/cvsd.c

Index: cvsd.c
===================================================================
RCS file: /home/arthur/devel/repos/cvsd/cvsd.c,v
retrieving revision 1.117
retrieving revision 1.118
diff -u -b -r1.117 -r1.118
--- cvsd.c      14 Jan 2010 21:29:08 -0000      1.117
+++ cvsd.c      25 Aug 2010 21:24:53 -0000      1.118
@@ -459,9 +459,7 @@
     /* bind the socket to the specified port */
     if (bind(sock,addr->ai_addr,addr->ai_addrlen)<0)
     {
-      if ((errno==EADDRINUSE)&&(last!=NULL)&&
-          (last->ai_family==AF_INET6)&&
-          (addr->ai_family==AF_INET))
+      if (errno==EADDRINUSE)
       {
         log_log(LOG_DEBUG,"debug: bind() failed (ignored): 
%s",strerror(errno));
         if (close(sock))


--
To unsubscribe send an email to
cvsd-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/cvsd-commits