diff options
author | Neels Hofmeyr <neels@hofmeyr.de> | 2021-04-25 16:35:02 +0200 |
---|---|---|
committer | Neels Hofmeyr <neels@hofmeyr.de> | 2021-04-28 16:32:19 +0200 |
commit | e8bb7438cb05a74a5f1a103c6d080944e761571e (patch) | |
tree | e5f055628e0d8daa914b774483f5e7e652594a2b /src | |
parent | 730fc73bd2d44418fbb81a9cb5d3fdc3a7ec2914 (diff) |
lchan_release(): do not release UNUSED lchan
I noticed that lchan_release() is generally called in varying error
situations, so it makes sense to generally skip the release procedure
when the lchan is already in the UNUSED state.
Change-Id: I6e9faf682d1668388d5470419110408a098b9900
Diffstat (limited to 'src')
-rw-r--r-- | src/osmo-bsc/lchan_fsm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/osmo-bsc/lchan_fsm.c b/src/osmo-bsc/lchan_fsm.c index d58aac5f0..d2b717239 100644 --- a/src/osmo-bsc/lchan_fsm.c +++ b/src/osmo-bsc/lchan_fsm.c @@ -1592,7 +1592,7 @@ void lchan_release(struct gsm_lchan *lchan, bool do_rr_release, bool err, enum gsm48_rr_cause cause_rr, const struct osmo_plmn_id *last_eutran_plmn) { - if (!lchan || !lchan->fi) + if (!lchan || !lchan->fi || lchan->fi->state == LCHAN_ST_UNUSED) return; if (lchan->release.in_release_handler) |