summaryrefslogtreecommitdiff
path: root/proto
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2010-09-03 16:32:00 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2010-09-03 16:32:00 +0200
commit3cb6c83f1a2eb563e459ce34d0f4850cc9dd4776 (patch)
treedd2935d890ae9287efe974a42a51d02f8e22dadd /proto
parentfaf58cec4d0c0d3c1fddee6faf2f57a1362477bb (diff)
Fixes a memory leak in RIP.
Diffstat (limited to 'proto')
-rw-r--r--proto/rip/rip.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/proto/rip/rip.c b/proto/rip/rip.c
index 0e5320c8..4b60d751 100644
--- a/proto/rip/rip.c
+++ b/proto/rip/rip.c
@@ -269,6 +269,8 @@ rip_rte_update_if_better(rtable *tab, net *net, struct proto *p, rte *new)
(ipa_equal(old->attrs->from, new->attrs->from) &&
(old->u.rip.metric != new->u.rip.metric)) )
rte_update(tab, net, p, p, new);
+ else
+ rte_free(new);
}
/*