summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2016-05-05 21:04:11 +0200
committerHarald Welte <laforge@gnumonks.org>2016-05-05 21:04:11 +0200
commit590eb20620107cd04677c10e9d4bc1aebe20a467 (patch)
treee2a734c7cfb932f735d7b2c8767aa44183fd804e
parent82a583b6ba3f7d02d9c65eb735b8e57c22426fec (diff)
LU: correctly determine and use is_ps
Don't use a local uninitialized variable but the luop->is_ps instead.
-rw-r--r--osmo-gsup-hlr/src/hlr.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/osmo-gsup-hlr/src/hlr.c b/osmo-gsup-hlr/src/hlr.c
index 0e31a43..96e211a 100644
--- a/osmo-gsup-hlr/src/hlr.c
+++ b/osmo-gsup-hlr/src/hlr.c
@@ -342,7 +342,6 @@ static int rx_upd_loc_req(struct osmo_gsup_conn *conn,
const struct osmo_gsup_message *gsup)
{
int rc;
- bool is_ps;
struct lu_operation *luop;
struct hlr_subscriber *subscr;
uint8_t *peer_addr;
@@ -374,10 +373,10 @@ static int rx_upd_loc_req(struct osmo_gsup_conn *conn,
/* Check if subscriber is generally permitted on CS or PS
* service (as requested) */
- if (!is_ps && !subscr->nam_cs) {
+ if (!luop->is_ps && !subscr->nam_cs) {
lu_op_tx_error(luop, GMM_CAUSE_PLMN_NOTALLOWED);
return 0;
- } else if (is_ps && !subscr->nam_ps) {
+ } else if (luop->is_ps && !subscr->nam_ps) {
lu_op_tx_error(luop, GMM_CAUSE_GPRS_NOTALLOWED);
return 0;
}