aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2021-09-14 12:25:55 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2021-09-15 16:17:37 +0200
commitc2ba34d9c13d309926c760943a9531fd3b236189 (patch)
treecc02b68ceaa9d99a05de526b4d8b59ecbee45a3c
parente1dbc616b0e72dc14b700c6104dd77beec8768ca (diff)
abis: Clear code and drop code not executed
abis_init() sets "g_bts = bts;", hence bts object is the same as g_bts (since we only have 1 BTS object in osmo-bts). As a result, dropping checking first bts->... and later g_bts->... makes no sense: the later condition will always be false. Change-Id: I5018199221fb3c3329a59d0b91e827f077cef85d
-rw-r--r--src/common/abis.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/common/abis.c b/src/common/abis.c
index 3325fabe..7503798d 100644
--- a/src/common/abis.c
+++ b/src/common/abis.c
@@ -102,18 +102,12 @@ static void abis_link_connected(struct osmo_fsm_inst *fi, uint32_t event, void *
LOGP(DABIS, LOGL_FATAL, "OML link was closed early within %" PRIu64 " seconds. "
"If this situation persists, please check your BTS and BSC configuration files for errors. "
"A common error is a mismatch between unit_id configuration parameters of BTS and BSC.\n",
- (uint64_t) (now.tv_sec - g_bts->oml_conn_established_timestamp.tv_sec));
+ (uint64_t) (now.tv_sec - bts->oml_conn_established_timestamp.tv_sec));
}
bts->oml_link = NULL;
oml_rsl_was_connected = true;
}
- memset(&g_bts->oml_conn_established_timestamp, 0, sizeof(bts->oml_conn_established_timestamp));
-
- if (g_bts->osmo_link) {
- e1inp_sign_link_destroy(g_bts->osmo_link);
- g_bts->osmo_link = NULL;
- oml_rsl_was_connected = true;
- }
+ memset(&bts->oml_conn_established_timestamp, 0, sizeof(bts->oml_conn_established_timestamp));
/* Then iterate over the RSL signalling links */
llist_for_each_entry(trx, &bts->trx_list, list) {