summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2008-12-01 11:10:34 -0800
committerPaul Jakma <paul@quagga.net>2009-06-12 17:10:29 +0100
commit7fc626de5f618133ad2a478d13defa3a110b89ea (patch)
tree432ff0e4672eabc2ec6b0dcffc22dcc0aee532c8 /lib
parent66e5cd87194ae6fdd51061a91b4698bc0a652f6b (diff)
[cleanup] Make command nodes static
The cmd_nodes used to configure vty, can mostly be static so (basic data hiding 101).
Diffstat (limited to 'lib')
-rw-r--r--lib/command.c12
-rw-r--r--lib/filter.c4
-rw-r--r--lib/keychain.c4
-rw-r--r--lib/plist.c4
-rw-r--r--lib/routemap.c2
-rw-r--r--lib/smux.c2
6 files changed, 14 insertions, 14 deletions
diff --git a/lib/command.c b/lib/command.c
index 4887f94f..0bbd99e5 100644
--- a/lib/command.c
+++ b/lib/command.c
@@ -41,37 +41,37 @@ vector cmdvec = NULL;
struct host host;
/* Standard command node structures. */
-struct cmd_node auth_node =
+static struct cmd_node auth_node =
{
AUTH_NODE,
"Password: ",
};
-struct cmd_node view_node =
+static struct cmd_node view_node =
{
VIEW_NODE,
"%s> ",
};
-struct cmd_node restricted_node =
+static struct cmd_node restricted_node =
{
RESTRICTED_NODE,
"%s$ ",
};
-struct cmd_node auth_enable_node =
+static struct cmd_node auth_enable_node =
{
AUTH_ENABLE_NODE,
"Password: ",
};
-struct cmd_node enable_node =
+static struct cmd_node enable_node =
{
ENABLE_NODE,
"%s# ",
};
-struct cmd_node config_node =
+static struct cmd_node config_node =
{
CONFIG_NODE,
"%s(config)# ",
diff --git a/lib/filter.c b/lib/filter.c
index 7aeb8deb..af8d587f 100644
--- a/lib/filter.c
+++ b/lib/filter.c
@@ -1857,7 +1857,7 @@ config_write_access (struct vty *vty, afi_t afi)
}
/* Access-list node. */
-struct cmd_node access_node =
+static struct cmd_node access_node =
{
ACCESS_NODE,
"", /* Access list has no interface. */
@@ -1953,7 +1953,7 @@ access_list_init_ipv4 (void)
}
#ifdef HAVE_IPV6
-struct cmd_node access_ipv6_node =
+static struct cmd_node access_ipv6_node =
{
ACCESS_IPV6_NODE,
"",
diff --git a/lib/keychain.c b/lib/keychain.c
index af0a1d74..6719cebf 100644
--- a/lib/keychain.c
+++ b/lib/keychain.c
@@ -848,14 +848,14 @@ DEFUN (send_lifetime_duration_month_day,
argv[3], argv[4]);
}
-struct cmd_node keychain_node =
+static struct cmd_node keychain_node =
{
KEYCHAIN_NODE,
"%s(config-keychain)# ",
1
};
-struct cmd_node keychain_key_node =
+static struct cmd_node keychain_key_node =
{
KEYCHAIN_KEY_NODE,
"%s(config-keychain-key)# ",
diff --git a/lib/plist.c b/lib/plist.c
index 4b498c4d..0f802a83 100644
--- a/lib/plist.c
+++ b/lib/plist.c
@@ -2623,7 +2623,7 @@ prefix_list_reset_orf (void)
/* Prefix-list node. */
-struct cmd_node prefix_node =
+static struct cmd_node prefix_node =
{
PREFIX_NODE,
"", /* Prefix list has no interface. */
@@ -2732,7 +2732,7 @@ prefix_list_init_ipv4 (void)
#ifdef HAVE_IPV6
/* Prefix-list node. */
-struct cmd_node prefix_ipv6_node =
+static struct cmd_node prefix_ipv6_node =
{
PREFIX_IPV6_NODE,
"", /* Prefix list has no interface. */
diff --git a/lib/routemap.c b/lib/routemap.c
index 58ed09a7..5f7a3182 100644
--- a/lib/routemap.c
+++ b/lib/routemap.c
@@ -1280,7 +1280,7 @@ route_map_config_write (struct vty *vty)
}
/* Route map node structure. */
-struct cmd_node rmap_node =
+static struct cmd_node rmap_node =
{
RMAP_NODE,
"%s(config-route-map)# ",
diff --git a/lib/smux.c b/lib/smux.c
index fd0c89c2..349cc2f7 100644
--- a/lib/smux.c
+++ b/lib/smux.c
@@ -73,7 +73,7 @@ int debug_smux = 0;
int fail = 0;
/* SMUX node. */
-struct cmd_node smux_node =
+static struct cmd_node smux_node =
{
SMUX_NODE,
"" /* SMUX has no interface. */