2004-09-17 Paul Jakma <paul@dishone.st>
* ripngd/ripngd.c: move setsockopt_so_recvbuf to lib.
* lib/sockopt.{c,h}: Add setsockopt_so_recvbuf, for ripd and ripngd.
* ripd/ripd.c: set receive buffer to a decent size, some systems
have low defaults. Problem noted and fix suggested by Stephan
Schweizer in [zebra 20967].
diff --git a/ripngd/ChangeLog b/ripngd/ChangeLog
index 6b05f3d..64ee7d8 100644
--- a/ripngd/ChangeLog
+++ b/ripngd/ChangeLog
@@ -1,3 +1,7 @@
+2004-09-17 Paul Jakma <paul@dishone.st>
+
+ * ripngd.c: move setsockopt_so_recvbuf to lib.
+
2004-07-23 Hasso Tepper <hasso@estpak.ee>
* ripng_interface.c, ripng_nexthop.c: use ifp->mtu6 instead of
diff --git a/ripngd/ripngd.c b/ripngd/ripngd.c
index b1edd6f..77e4754 100644
--- a/ripngd/ripngd.c
+++ b/ripngd/ripngd.c
@@ -107,17 +107,6 @@
XFREE (MTYPE_RIPNG_ROUTE, rinfo);
}
-static int
-setsockopt_so_recvbuf (int sock, int size)
-{
- int ret;
-
- ret = setsockopt (sock, SOL_SOCKET, SO_RCVBUF, (char *) &size, sizeof (int));
- if (ret < 0)
- zlog (NULL, LOG_ERR, "can't setsockopt SO_RCVBUF");
- return ret;
-}
-
/* Create ripng socket. */
int
ripng_make_socket (void)