aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Couzens <lynxis@fe80.eu>2019-08-13 11:31:42 +0200
committerAlexander Couzens <lynxis@fe80.eu>2019-08-23 22:58:14 +0200
commita2b99de60a80c99559d42f17855ab5c930628a04 (patch)
treea381dc5af1b7969eb88009d2e552d44099b791f7
parentca20710c589d37e09e1bfd977d08d4e3572fd80a (diff)
gprs_gmm: refactor msgid2mmctx() out of switch/case
-rw-r--r--src/gprs/gprs_gmm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gprs/gprs_gmm.c b/src/gprs/gprs_gmm.c
index ce718034..0b1f6c73 100644
--- a/src/gprs/gprs_gmm.c
+++ b/src/gprs/gprs_gmm.c
@@ -1461,7 +1461,6 @@ static int gsm48_rx_gmm_att_req(struct sgsn_mm_ctx *ctx, struct msgb *msg,
ctx->gb.tlli = msgb_tlli(msg);
ctx->gb.llme = llme;
}
- msgid2mmctx(ctx, msg);
break;
case GSM_MI_TYPE_TMSI:
memcpy(&tmsi, mi+1, 4);
@@ -1486,7 +1485,6 @@ static int gsm48_rx_gmm_att_req(struct sgsn_mm_ctx *ctx, struct msgb *msg,
ctx->gb.tlli = msgb_tlli(msg);
ctx->gb.llme = llme;
}
- msgid2mmctx(ctx, msg);
break;
default:
LOGMMCTXP(LOGL_NOTICE, ctx, "Rejecting ATTACH REQUEST with "
@@ -1494,6 +1492,8 @@ static int gsm48_rx_gmm_att_req(struct sgsn_mm_ctx *ctx, struct msgb *msg,
reject_cause = GMM_CAUSE_MS_ID_NOT_DERIVED;
goto rejected;
}
+
+ msgid2mmctx(ctx, msg);
/* Update MM Context with currient RA and Cell ID */
ctx->ra = ra_id;
if (ctx->ran_type == MM_CTX_T_GERAN_Gb)