From 1fe1d15e5fc4126b1cce0bd19c56afac1d4cd4f0 Mon Sep 17 00:00:00 2001 From: Pau Espin Pedrol Date: Tue, 18 Oct 2022 14:33:15 +0200 Subject: [PATCH] vty: Make use of new mgcp_client_pool_config_write() API Let's use the new API available in libosmo-mgcp-client to control more consciously where the mgw pool config is printed. Before this patch, the place where the node was printed was defined based on implementation details on how the enum of nodes are defined and installed. Related: SYS#5987 Depends: osmo-mgw.git Change-Id I7a620cf47886d8ecab30ce369cf123d98ab842c5 Change-Id: Ic473fe05c55e8df3eddedf0260ec04b6fefc501f --- TODO-RELEASE | 1 + src/libmsc/msc_vty.c | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/TODO-RELEASE b/TODO-RELEASE index d0852fc9b..502fff608 100644 --- a/TODO-RELEASE +++ b/TODO-RELEASE @@ -7,3 +7,4 @@ # If any interfaces have been added since the last public release: c:r:a + 1. # If any interfaces have been removed or changed since the last public release: c:r:0. #library what description / commit summary line +libosmo-mgcp-client >1.10.0 mgcp_client_pool_config_write() \ No newline at end of file diff --git a/src/libmsc/msc_vty.c b/src/libmsc/msc_vty.c index 357b9754b..b28ed0d64 100644 --- a/src/libmsc/msc_vty.c +++ b/src/libmsc/msc_vty.c @@ -390,6 +390,8 @@ static int config_write_net(struct vty *vty) if (!gsmnet->call_waiting) vty_out(vty, " no call-waiting%s", VTY_NEWLINE); + mgcp_client_pool_config_write(vty, " "); + return CMD_SUCCESS; } @@ -2033,7 +2035,7 @@ void msc_vty_init(struct gsm_network *msc_network) install_element(GSMNET_NODE, &cfg_net_no_per_loc_upd_cmd); install_element(GSMNET_NODE, &cfg_net_call_wait_cmd); install_element(GSMNET_NODE, &cfg_net_no_call_wait_cmd); - mgcp_client_pool_vty_init(GSMNET_NODE, MGW_NODE, " ", msc_network->mgw.mgw_pool); + mgcp_client_pool_vty_init(GSMNET_NODE, MGW_NODE, NULL, msc_network->mgw.mgw_pool); install_element(CONFIG_NODE, &cfg_msc_cmd);