diff options
author | 2015-04-04 16:29:48 +0000 | |
---|---|---|
committer | 2015-04-04 16:29:48 +0000 | |
commit | 0435c20eb82c0ebdb06f6a7642dcce2fe660600d (patch) | |
tree | 8fab586677d91b353030a717c2c9ef47955fcc47 /usr.sbin/ldpctl/ldpctl.c | |
parent | Remove lo protection. (diff) | |
download | wireguard-openbsd-0435c20eb82c0ebdb06f6a7642dcce2fe660600d.tar.xz wireguard-openbsd-0435c20eb82c0ebdb06f6a7642dcce2fe660600d.zip |
Show the remote labels in "ldpctl show lib" even if they are not installed in the FIB.
ok claudio@
Diffstat (limited to 'usr.sbin/ldpctl/ldpctl.c')
-rw-r--r-- | usr.sbin/ldpctl/ldpctl.c | 10 |
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) |