summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2012-05-04 23:05:47 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2012-05-11 12:10:21 +0200
commit47c447c42e0bfa1836d951d1e6c1a2236d39dcbb (patch)
tree4bf10914440cb7d2df02fcfa7f7c2733a582cd6e
parent95616c820248018f4999972cad315f2da60e4960 (diff)
Minor cleanups.
-rw-r--r--nest/rt-table.c5
-rw-r--r--proto/bgp/packets.c3
-rw-r--r--proto/rip/rip.c5
-rw-r--r--sysdep/linux/sysio.h2
4 files changed, 4 insertions, 11 deletions
diff --git a/nest/rt-table.c b/nest/rt-table.c
index bb0ee4c8..fdc767e7 100644
--- a/nest/rt-table.c
+++ b/nest/rt-table.c
@@ -799,10 +799,7 @@ void
rte_dump(rte *e)
{
net *n = e->net;
- if (n)
- debug("%-1I/%2d ", n->n.prefix, n->n.pxlen);
- else
- debug("??? ");
+ debug("%-1I/%2d ", n->n.prefix, n->n.pxlen);
debug("KF=%02x PF=%02x pref=%d lm=%d ", n->n.flags, e->pflags, e->pref, now-e->lastmod);
rta_dump(e->attrs);
if (e->attrs->proto->proto->dump_attrs)
diff --git a/proto/bgp/packets.c b/proto/bgp/packets.c
index 168025d0..cfa37fb5 100644
--- a/proto/bgp/packets.c
+++ b/proto/bgp/packets.c
@@ -1031,9 +1031,6 @@ bgp_do_rx_update(struct bgp_conn *conn,
if (n = net_find(p->p.table, prefix, pxlen))
rte_update(p->p.table, n, &p->p, &p->p, NULL);
}
-
- if (bgp_apply_limits(p) < 0)
- goto done;
}
}
diff --git a/proto/rip/rip.c b/proto/rip/rip.c
index b41c3f8d..281296a5 100644
--- a/proto/rip/rip.c
+++ b/proto/rip/rip.c
@@ -624,7 +624,6 @@ rip_dump(struct proto *p)
int i;
node *w;
struct rip_interface *rif;
- i = 0;
CHK_MAGIC;
WALK_LIST( w, P->connections ) {
@@ -995,8 +994,8 @@ static int
rip_get_attr(eattr *a, byte *buf, int buflen UNUSED)
{
switch (a->id) {
- case EA_RIP_METRIC: buf += bsprintf( buf, "metric: %d", a->u.data ); return GA_FULL;
- case EA_RIP_TAG: buf += bsprintf( buf, "tag: %d", a->u.data ); return GA_FULL;
+ case EA_RIP_METRIC: bsprintf( buf, "metric: %d", a->u.data ); return GA_FULL;
+ case EA_RIP_TAG: bsprintf( buf, "tag: %d", a->u.data ); return GA_FULL;
default: return GA_UNKNOWN;
}
}
diff --git a/sysdep/linux/sysio.h b/sysdep/linux/sysio.h
index 705a20ae..90b3ebd9 100644
--- a/sysdep/linux/sysio.h
+++ b/sysdep/linux/sysio.h
@@ -301,7 +301,7 @@ sk_set_min_ttl6(sock *s, int ttl)
if (errno == ENOPROTOOPT)
log(L_ERR "Kernel does not support IPv6 TTL security");
else
- log(L_ERR "sk_set_min_ttl4: setsockopt: %m");
+ log(L_ERR "sk_set_min_ttl6: setsockopt: %m");
return -1;
}