aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2012-11-13 21:54:36 +0100
committerHolger Hans Peter Freyther <zecke@selfish.org>2013-04-16 09:17:21 +0200
commitac04d8d55e413d49ef0a9179bccf1147e6f2a87a (patch)
tree73db75000d7a85120f316967e826a80a43c62914
parent7d7054eafa76f1b9cda588c6a46229f732b7ccad (diff)
nat: Name the variable more properly and begin with net.1.bsc.%d
We can identify the NAT and BSC given the types of the variable, no need to put them into the value itself.
-rw-r--r--openbsc/src/osmo-bsc_nat/bsc_mgcp_utils.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/openbsc/src/osmo-bsc_nat/bsc_mgcp_utils.c b/openbsc/src/osmo-bsc_nat/bsc_mgcp_utils.c
index 226486c32..85f940b49 100644
--- a/openbsc/src/osmo-bsc_nat/bsc_mgcp_utils.c
+++ b/openbsc/src/osmo-bsc_nat/bsc_mgcp_utils.c
@@ -435,10 +435,11 @@ static void handle_dlcx_response(struct bsc_connection *bsc, struct msgb *msg,
}
cmd->id = "0";
- cmd->variable = "nat.call_stats.v2";
+ cmd->variable = talloc_asprintf(cmd, "net.0.bsc.%d.call_stats.v2",
+ bsc->cfg->nr);
cmd->reply = talloc_asprintf(cmd,
- "bsc_id=%d,mg_ip_addr=%s,mg_port=%d,",
- bsc->cfg->nr, inet_ntoa(stat->net_addr),
+ "mg_ip_addr=%s,mg_port=%d,",
+ inet_ntoa(stat->net_addr),
stat->net_rtp_port);
cmd->reply = talloc_asprintf_append(cmd->reply,
"endpoint_ip_addr=%s,endpoint_port=%d,",