gb_proxy: Don't use bssgp_nsi variable, but cfg->{bss,sgsn}_nsi
The global variable bssgp_nsi should disappear soon to make the gb_proxy
work with different NS instances on the SGSN and the BSS side. Let's
remove any code that explicitly references bssgp_nsi during message
processing.
Change-Id: Iac6c5d318fde41fb6edab3cb11b4773c62bb4ef6
diff --git a/openbsc/src/gprs/gb_proxy.c b/openbsc/src/gprs/gb_proxy.c
index a363bb9..83219ed 100644
--- a/openbsc/src/gprs/gb_proxy.c
+++ b/openbsc/src/gprs/gb_proxy.c
@@ -761,7 +761,7 @@
strip_ns_hdr(msg);
- rc = gprs_ns_sendmsg(bssgp_nsi, msg);
+ rc = gprs_ns_sendmsg(cfg->sgsn_nsi, msg);
if (rc < 0)
rate_ctr_inc(&cfg->ctrg->ctr[GBPROX_GLOB_CTR_TX_ERR_SGSN]);
@@ -786,7 +786,7 @@
/* Strip the old NS header, it will be replaced with a new one */
strip_ns_hdr(msg);
- rc = gprs_ns_sendmsg(bssgp_nsi, msg);
+ rc = gprs_ns_sendmsg(peer->cfg->bss_nsi, msg);
if (rc < 0)
rate_ctr_inc(&peer->ctrg->ctr[GBPROX_PEER_CTR_TX_ERR]);