summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-09-11 13:41:41 +0800
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-09-11 13:41:41 +0800
commit2e228fc2af9df41517163fd6575ff509c33096ad (patch)
tree3c10c1f4746bae84a7f18a5d783829280d1e9a72
parente25b18aa29a7b7bac7d2574a83b9049d043c1547 (diff)
vty: Use the copyright string from the app_info.
-rw-r--r--src/vty/telnet_interface.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/vty/telnet_interface.c b/src/vty/telnet_interface.c
index 90690960..1523a899 100644
--- a/src/vty/telnet_interface.c
+++ b/src/vty/telnet_interface.c
@@ -31,6 +31,7 @@
#include <osmocom/vty/telnet_interface.h>
#include <osmocom/vty/buffer.h>
+#include <osmocom/vty/command.h>
/* per connection data */
LLIST_HEAD(active_connections);
@@ -89,16 +90,18 @@ int telnet_init(void *tall_ctx, void *priv, int port)
return 0;
}
-extern const char *openbsc_copyright;
+extern struct host host;
static void print_welcome(int fd)
{
int ret;
static char *msg =
- "Welcome to the OpenBSC Control interface\n";
+ "Welcome to the OpenBSC Control interface\r\n";
ret = write(fd, msg, strlen(msg));
- ret = write(fd, openbsc_copyright, strlen(openbsc_copyright));
+
+ if (host.app_info->copyright)
+ ret = write(fd, host.app_info->copyright, strlen(host.app_info->copyright));
}
int telnet_close_client(struct bsc_fd *fd)