From e041f6fa5c4353e27e715978a36cca4b22cffb69 Mon Sep 17 00:00:00 2001 From: octo Date: Thu, 1 Jun 2006 20:39:43 +0000 Subject: [PATCH] Removed the call to `bind'. It's only neccessary when binding to a specific (local) address, which we don't. FreeBSD, Mac OS X and potentially other operating systems didn't like this.. GNU/Linux never complained, though.. --- src/liboping/liboping.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/liboping/liboping.c b/src/liboping/liboping.c index afd44868..1ee23930 100644 --- a/src/liboping/liboping.c +++ b/src/liboping/liboping.c @@ -904,6 +904,7 @@ int ping_host_add (pingobj_t *obj, const char *host) continue; } +#if 0 if (bind (ph->fd, (struct sockaddr *) &sockaddr, sockaddr_len) == -1) { dprintf ("bind: %s\n", strerror (errno)); @@ -911,6 +912,7 @@ int ping_host_add (pingobj_t *obj, const char *host) ph->fd = -1; continue; } +#endif assert (sizeof (struct sockaddr_storage) >= ai_ptr->ai_addrlen); memset (ph->addr, '\0', sizeof (struct sockaddr_storage)); -- 2.30.2