diff options
author | Esben Norby <norby@cvs.openbsd.org> | 2005-12-04 20:49:48 +0000 |
---|---|---|
committer | Esben Norby <norby@cvs.openbsd.org> | 2005-12-04 20:49:48 +0000 |
commit | 7c35c969b24badc396b0df721f5418c0a1aba692 (patch) | |
tree | 803c8b0f12a2a79df1cc6a327515e002e1d05964 /usr.sbin/ospfd/interface.c | |
parent | 855285a7671aca79b64b58cc81aa4838bb4a8860 (diff) |
Increase the receive buffer of the raw socket.
Prevents some of the retransmitting during bulk ls update transfers.
ok claudio@
Diffstat (limited to 'usr.sbin/ospfd/interface.c')
-rw-r--r-- | usr.sbin/ospfd/interface.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/usr.sbin/ospfd/interface.c b/usr.sbin/ospfd/interface.c index 9534244682a..c22420c4779 100644 --- a/usr.sbin/ospfd/interface.c +++ b/usr.sbin/ospfd/interface.c @@ -1,4 +1,4 @@ -/* $OpenBSD: interface.c,v 1.38 2005/10/19 21:43:20 claudio Exp $ */ +/* $OpenBSD: interface.c,v 1.39 2005/12/04 20:49:47 norby Exp $ */ /* * Copyright (c) 2005 Claudio Jeker <claudio@openbsd.org> @@ -737,6 +737,17 @@ if_set_tos(int fd, int tos) return (0); } +void +if_set_recvbuf(int fd) +{ + int bsize; + + bsize = 65535; + while (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &bsize, + sizeof(bsize)) == -1) + bsize /= 2; +} + int if_join_group(struct iface *iface, struct in_addr *addr) { |