summaryrefslogtreecommitdiff
path: root/sysdep/unix/krt.c
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>1999-05-17 20:16:53 +0000
committerMartin Mares <mj@ucw.cz>1999-05-17 20:16:53 +0000
commit4f1a6d27b9a44f61329bc7b6779a0c645362e181 (patch)
tree4c77601930c97a225f42aaf9ce5dcc378459d1ec /sysdep/unix/krt.c
parent0e02abfd5770062768eeb4c75061b7d2f656489d (diff)
Kill remaining master_table relics in KRT code.
Make all protocols pass routing table to rte_update and rte_discard.
Diffstat (limited to 'sysdep/unix/krt.c')
-rw-r--r--sysdep/unix/krt.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sysdep/unix/krt.c b/sysdep/unix/krt.c
index 69d535bc..364147da 100644
--- a/sysdep/unix/krt.c
+++ b/sysdep/unix/krt.c
@@ -132,7 +132,7 @@ krt_learn_announce_update(struct krt_proto *p, rte *e)
ee->net = nn;
ee->pflags = 0;
ee->u.krt = e->u.krt;
- rte_update(nn, &p->p, ee);
+ rte_update(p->p.table, nn, &p->p, ee);
}
static void
@@ -140,7 +140,7 @@ krt_learn_announce_delete(struct krt_proto *p, net *n)
{
n = net_find(p->p.table, n->n.prefix, n->n.pxlen);
if (n)
- rte_update(n, &p->p, NULL);
+ rte_update(p->p.table, n, &p->p, NULL);
}
static void
@@ -356,7 +356,7 @@ krt_dump_attrs(rte *e)
static void
krt_flush_routes(struct krt_proto *p)
{
- struct rtable *t = &master_table;
+ struct rtable *t = p->p.table;
DBG("Flushing kernel routes...\n");
FIB_WALK(&t->fib, f)
@@ -466,7 +466,7 @@ static void
krt_prune(struct krt_proto *p)
{
struct proto *pp = &p->p;
- struct rtable *t = &master_table;
+ struct rtable *t = p->p.table;
struct fib_node *f;
DBG("Pruning routes...\n");
@@ -547,7 +547,7 @@ krt_got_route_async(struct krt_proto *p, rte *e, int new)
/* Fall-thru */
default:
DBG("Discarding\n");
- rte_update(net, &p->p, NULL);
+ rte_update(p->p.table, net, &p->p, NULL);
}
rte_free(e);
}