summaryrefslogtreecommitdiff
path: root/lib/ns.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ns.c')
-rw-r--r--lib/ns.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/ns.c b/lib/ns.c
index 5e6bddf0d8..5af896632c 100644
--- a/lib/ns.c
+++ b/lib/ns.c
@@ -218,6 +218,13 @@ void ns_walk_func(int (*func)(struct ns *))
func(ns);
}
+const char *ns_get_name(struct ns *ns)
+{
+ if (!ns)
+ return NULL;
+ return ns->name;
+}
+
/* Look up a NS by name */
static struct ns *ns_lookup_name(const char *name)
{