summaryrefslogtreecommitdiffstats
path: root/sysdep/bsd
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2010-07-05 17:50:19 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2010-07-05 17:50:19 +0200
commitcfe34a316e35a209fcd814ccf3523c262e8d4b0a (patch)
tree29046cfeb797ade6a3c879b5d58f93cd414ab14d /sysdep/bsd
parent824de84d48eff6cbd0c550309fbd0bbf7740cb14 (diff)
downloadbird-cfe34a316e35a209fcd814ccf3523c262e8d4b0a.tar
bird-cfe34a316e35a209fcd814ccf3523c262e8d4b0a.zip
Implements hostcache and recursive next hops.
Hostcache is a structure for monitoring changes in a routing table that is used for routes with dynamic/recursive next hops. This is needed for proper iBGP next hop handling.
Diffstat (limited to 'sysdep/bsd')
-rw-r--r--sysdep/bsd/krt-sock.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/sysdep/bsd/krt-sock.c b/sysdep/bsd/krt-sock.c
index 4c8676e..9ae658d 100644
--- a/sysdep/bsd/krt-sock.c
+++ b/sysdep/bsd/krt-sock.c
@@ -244,7 +244,6 @@ krt_set_start(struct krt_proto *x, int first UNUSED)
static void
krt_read_rt(struct ks_msg *msg, struct krt_proto *p, int scan)
{
- rta a;
rte *e;
net *net;
sockaddr dst, gate, mask;
@@ -329,17 +328,12 @@ krt_read_rt(struct ks_msg *msg, struct krt_proto *p, int scan)
net = net_get(p->p.table, idst, pxlen);
- bzero(&a, sizeof(a));
-
- a.proto = &p->p;
- a.source = RTS_INHERIT;
- a.scope = SCOPE_UNIVERSE;
- a.cast = RTC_UNICAST;
- a.flags = a.aflags = 0;
- a.from = IPA_NONE;
- a.gw = IPA_NONE;
- a.iface = NULL;
- a.eattrs = NULL;
+ rta a = {
+ .proto = &p->p,
+ .source = RTS_INHERIT,
+ .scope = SCOPE_UNIVERSE,
+ .cast = RTC_UNICAST
+ };
/* reject/blackhole routes have also set RTF_GATEWAY,
we wil check them first. */