diff options
author | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2016-10-13 14:43:49 +0200 |
---|---|---|
committer | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2016-10-13 15:17:06 +0200 |
commit | c7ccdd490f84914754c72c7b3105772f74a40208 (patch) | |
tree | 0f3e535e9a655ed4c0da787452f8a628df091de8 /src/hnbgw_vty.c | |
parent | 4ff1a5a957859ceec50f3f191399da5163198ff5 (diff) |
cosmetic: hnbgw: addr related renames, move define, move comment
Prepare for parameterization of IuCS and IuPS addresses:
Conform internal variable naming to local-ip, local-port, remote-ip,
remote-port (instead of bind-ip).
Rename HNBGW_IUH_LOCAL_IP_DEFAULT to HNGGW_LOCAL_IP_DEFAULT to be more general
and move it to the top.
Move a function doc comment to the .c file.
Change-Id: Ice85941c978498e3ddf41d151248507e7f56cb5d
Diffstat (limited to 'src/hnbgw_vty.c')
-rw-r--r-- | src/hnbgw_vty.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/hnbgw_vty.c b/src/hnbgw_vty.c index 5dee41a..93c1f9a 100644 --- a/src/hnbgw_vty.c +++ b/src/hnbgw_vty.c @@ -107,10 +107,10 @@ DEFUN(show_talloc, show_talloc_cmd, "show talloc", SHOW_STR "Display talloc info DEFUN(cfg_hnbgw_iuh_local_ip, cfg_hnbgw_iuh_local_ip_cmd, "local-ip A.B.C.D", "Accept Iuh connections on local interface\n" - "Local interface IP address (default: " HNBGW_IUH_LOCAL_IP_DEFAULT ")") + "Local interface IP address (default: " HNBGW_LOCAL_IP_DEFAULT ")") { - talloc_free((void*)g_hnb_gw->config.iuh_bind_addr); - g_hnb_gw->config.iuh_bind_addr = talloc_strdup(tall_hnb_ctx, argv[0]); + talloc_free((void*)g_hnb_gw->config.iuh_local_ip); + g_hnb_gw->config.iuh_local_ip = talloc_strdup(tall_hnb_ctx, argv[0]); return CMD_SUCCESS; } @@ -136,8 +136,8 @@ static int config_write_hnbgw_iuh(struct vty *vty) vty_out(vty, " iuh%s", VTY_NEWLINE); - addr = g_hnb_gw->config.iuh_bind_addr; - if (addr && (strcmp(addr, HNBGW_IUH_LOCAL_IP_DEFAULT) != 0)) + addr = g_hnb_gw->config.iuh_local_ip; + if (addr && (strcmp(addr, HNBGW_LOCAL_IP_DEFAULT) != 0)) vty_out(vty, " local-ip %s%s", addr, VTY_NEWLINE); if (g_hnb_gw->config.hnbap_allow_tmsi) |