summaryrefslogtreecommitdiff
path: root/ripd
diff options
context:
space:
mode:
authorpaul <paul>2004-09-17 08:39:08 +0000
committerpaul <paul>2004-09-17 08:39:08 +0000
commit0b3acf4f94241905ff36df5c1d9f9f389e45d191 (patch)
tree48b312ab2de446208d966d234fc37539bed98861 /ripd
parentbf731011ef7038f5766432fec862301c123d4736 (diff)
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].
Diffstat (limited to 'ripd')
-rw-r--r--ripd/ChangeLog6
-rw-r--r--ripd/ripd.c5
2 files changed, 11 insertions, 0 deletions
diff --git a/ripd/ChangeLog b/ripd/ChangeLog
index 8ab8a103..1921b789 100644
--- a/ripd/ChangeLog
+++ b/ripd/ChangeLog
@@ -1,3 +1,9 @@
+2004-09-17 Paul Jakma <paul@dishone.st>
+
+ * 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].
+
2004-08-19 Paul Jakma <paul@dishone.st>
* rip_interface.c: (rip_interface_multicast_set) get rid
diff --git a/ripd/ripd.c b/ripd/ripd.c
index af0e186d..5fbb3492 100644
--- a/ripd/ripd.c
+++ b/ripd/ripd.c
@@ -42,6 +42,10 @@
#include "ripd/ripd.h"
#include "ripd/rip_debug.h"
+/* UDP receive buffer size */
+#define RIP_UDP_RCV_BUF 41600
+
+/* privileges global */
extern struct zebra_privs_t ripd_privs;
/* RIP Structure. */
@@ -1977,6 +1981,7 @@ rip_create_socket ()
sockopt_broadcast (sock);
sockopt_reuseaddr (sock);
sockopt_reuseport (sock);
+ setsockopt_so_recvbuf (sock, RIP_UDP_RCV_BUF);
#ifdef RIP_RECVMSG
setsockopt_pktinfo (sock);
#endif /* RIP_RECVMSG */