summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRenato Westphal <renato@cvs.openbsd.org>2015-04-04 16:29:49 +0000
committerRenato Westphal <renato@cvs.openbsd.org>2015-04-04 16:29:49 +0000
commit506f9818b8492e36d1b35e5a6ce5440b69bd4ec9 (patch)
tree791a35f8e56a1194995cfc9fb91acc638a2a31df
parentcb1a0947fba1e5f5052035dd86023be3381461b4 (diff)
Show the remote labels in "ldpctl show lib" even if they are not installed in the FIB.
ok claudio@
-rw-r--r--usr.sbin/ldpctl/ldpctl.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/usr.sbin/ldpctl/ldpctl.c b/usr.sbin/ldpctl/ldpctl.c
index c6e46609f1d..d6db8150783 100644
--- a/usr.sbin/ldpctl/ldpctl.c
+++ b/usr.sbin/ldpctl/ldpctl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ldpctl.c,v 1.17 2015/01/15 23:51:04 deraadt Exp $
+/* $OpenBSD: ldpctl.c,v 1.18 2015/04/04 16:29:48 renato Exp $
*
* Copyright (c) 2009 Michele Marchetto <michele@openbsd.org>
* Copyright (c) 2005 Claudio Jeker <claudio@openbsd.org>
@@ -372,11 +372,9 @@ show_lib_msg(struct imsg *imsg)
if (asprintf(&dstnet, "%s/%d", inet_ntoa(rt->prefix),
rt->prefixlen) == -1)
err(1, NULL);
- if (!rt->in_use) {
- if (asprintf(&remote, "-") == -1)
- err(1, NULL);
- } else if (rt->connected || rt->remote_label == NO_LABEL) {
- if (asprintf(&remote, "Untagged") == -1)
+
+ if (rt->remote_label == NO_LABEL) {
+ if (asprintf(&remote, "No Label") == -1)
err(1, NULL);
} else if (rt->remote_label == MPLS_LABEL_IMPLNULL) {
if (asprintf(&remote, "Pop tag") == -1)