From 9c0b0e6753b110a7e0ba4229873a6c10cd8c6bd5 Mon Sep 17 00:00:00 2001 From: Renato Westphal Date: Wed, 14 Dec 2016 19:20:10 -0200 Subject: [PATCH] ldpd: allow multiple link adjacencies with unnumbered interfaces Now we can have two different adjacencies coming from the same source address. Check for the adjacency's interface on adj_find() to disambiguate them. Signed-off-by: Renato Westphal --- ldpd/adjacency.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ldpd/adjacency.c b/ldpd/adjacency.c index 3607ee96b3..d1a6facb30 100644 --- a/ldpd/adjacency.c +++ b/ldpd/adjacency.c @@ -117,6 +117,10 @@ adj_find(struct hello_source *source) switch (source->type) { case HELLO_LINK: + if (strcmp(source->link.ia->iface->name, + adj->source.link.ia->iface->name)) + continue; + if (ldp_addrcmp(source->link.ia->af, &adj->source.link.src_addr, &source->link.src_addr) == 0) -- 2.39.5