summaryrefslogtreecommitdiff
path: root/lib/command.c
diff options
context:
space:
mode:
authorhasso <hasso>2004-10-19 20:40:08 +0000
committerhasso <hasso>2004-10-19 20:40:08 +0000
commit6590f2c3dc10acaa04cea3206fd00445e0a6145c (patch)
tree6ca50941520649a19f7488a45a4ca2f9b7f84ef1 /lib/command.c
parent3fb9cd6ef456959b6eff939d5c316f6785c2dda4 (diff)
Small copyright string and hostname related cleanup.
Diffstat (limited to 'lib/command.c')
-rw-r--r--lib/command.c30
1 files changed, 18 insertions, 12 deletions
diff --git a/lib/command.c b/lib/command.c
index 4495d221..fc115d95 100644
--- a/lib/command.c
+++ b/lib/command.c
@@ -36,13 +36,6 @@ vector cmdvec;
/* Host information structure. */
struct host host;
-/* Default motd string. */
-const char *default_motd =
-"\r\n\
-Hello, this is " QUAGGA_PROGNAME " (version " QUAGGA_VERSION ").\r\n\
-Copyright 1996-2004 Kunihiro Ishiguro, et al.\r\n\
-\r\n";
-
/* Standard command node structures. */
struct cmd_node auth_node =
{
@@ -74,6 +67,21 @@ struct cmd_node config_node =
"%s(config)# ",
1
};
+
+/* Default motd string. */
+const char *default_motd =
+"\r\n\
+Hello, this is " QUAGGA_PROGNAME " (version " QUAGGA_VERSION ").\r\n\
+" QUAGGA_COPYRIGHT "\r\n\
+\r\n";
+
+void
+print_version (const char *progname)
+{
+ printf ("%s version %s (%s)\n", progname, QUAGGA_VERSION, host.name);
+ printf ("%s\n", QUAGGA_COPYRIGHT);
+}
+
/* Utility function to concatenate argv argument into a single string
with inserting ' ' character between each argument. */
@@ -2397,10 +2405,8 @@ DEFUN (show_version,
SHOW_STR
"Displays zebra version\n")
{
- vty_out (vty, "Quagga %s (%s).%s", QUAGGA_VERSION,
- host_name,
- VTY_NEWLINE);
- vty_out (vty, "Copyright 1996-2002, Kunihiro Ishiguro.%s", VTY_NEWLINE);
+ vty_out (vty, "Quagga %s (%s).%s", QUAGGA_VERSION, host.name, VTY_NEWLINE);
+ vty_out (vty, "%s%s", QUAGGA_COPYRIGHT, VTY_NEWLINE);
return CMD_SUCCESS;
}
@@ -2412,7 +2418,7 @@ DEFUN (config_help,
"Description of the interactive help system\n")
{
vty_out (vty,
- "Zebra VTY provides advanced help feature. When you need help,%s\
+ "Quagga VTY provides advanced help feature. When you need help,%s\
anytime at the command line please press '?'.%s\
%s\
If nothing matches, the help list will be empty and you must backup%s\