summaryrefslogtreecommitdiffstats
path: root/sysdep/unix
diff options
context:
space:
mode:
authorOndrej Filip <feela@network.cz>2004-06-03 10:18:14 +0200
committerOndrej Filip <feela@network.cz>2004-06-03 10:18:14 +0200
commit7d72aadb8acfac16e9b637e6ebb5ce288ebf1d77 (patch)
treef082b3abfc6df9858a65f271d7075e6549e51ec7 /sysdep/unix
parentcb4dd4e2f78f806438bfb8163b783ac7b2f43b2d (diff)
downloadbird-7d72aadb8acfac16e9b637e6ebb5ce288ebf1d77.tar
bird-7d72aadb8acfac16e9b637e6ebb5ce288ebf1d77.zip
CONFIG_SKIP_MC_BIND added.
BSD hates it, Linux needs it.
Diffstat (limited to 'sysdep/unix')
-rw-r--r--sysdep/unix/io.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sysdep/unix/io.c b/sysdep/unix/io.c
index 070150f..bf97e53 100644
--- a/sysdep/unix/io.c
+++ b/sysdep/unix/io.c
@@ -754,7 +754,11 @@ sk_open(sock *s)
ERR("SO_REUSEADDR");
}
fill_in_sockaddr(&sa, s->saddr, port);
+#ifdef CONFIG_SKIP_MC_BIND
+ if (type == SK_IP && bind(fd, (struct sockaddr *) &sa, sizeof(sa)) < 0)
+#else
if (bind(fd, (struct sockaddr *) &sa, sizeof(sa)) < 0)
+#endif
ERR("bind");
}
fill_in_sockaddr(&sa, s->daddr, s->dport);