diff options
Diffstat (limited to 'src/vty/logging_vty.c')
-rw-r--r-- | src/vty/logging_vty.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vty/logging_vty.c b/src/vty/logging_vty.c index c39017b9..dc457ffc 100644 --- a/src/vty/logging_vty.c +++ b/src/vty/logging_vty.c @@ -537,7 +537,7 @@ DEFUN(cfg_log_gsmtap, cfg_log_gsmtap_cmd, LOG_STR "Logging via GSMTAP\n" "Host name to send the GSMTAP logging to (UDP port 4729)\n") { - const char *hostname = argv[0]; + const char *hostname = argc ? argv[0] : "127.0.0.1"; struct log_target *tgt; tgt = log_target_find(LOG_TGT_TYPE_GSMTAP, hostname); @@ -546,8 +546,8 @@ DEFUN(cfg_log_gsmtap, cfg_log_gsmtap_cmd, host.app_info->name, false, true); if (!tgt) { - vty_out(vty, "%% Unable to create GSMTAP log%s", - VTY_NEWLINE); + vty_out(vty, "%% Unable to create GSMTAP log for %s%s", + hostname, VTY_NEWLINE); return CMD_WARNING; } log_add_target(tgt); |