From 7d621e0a79e940864cc3d3d4a057ccea9aeeb64a Mon Sep 17 00:00:00 2001 From: Pau Espin Pedrol Date: Wed, 4 May 2022 16:09:59 +0200 Subject: constify state pointers of struct gsm_nm_state This makes sure code accessing those fields is not changing its values, since it would make no sense to change those. Follow up commit will make convert those pointers to be full structs instead, as there's no need to have pointers there. Change-Id: I9979e62eac861e25bbe2161ab187ddb2b40fd097 --- src/osmo-bsc/nm_bts_sm_fsm.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/osmo-bsc/nm_bts_sm_fsm.c') diff --git a/src/osmo-bsc/nm_bts_sm_fsm.c b/src/osmo-bsc/nm_bts_sm_fsm.c index 1bb182df2..b99fb53f7 100644 --- a/src/osmo-bsc/nm_bts_sm_fsm.c +++ b/src/osmo-bsc/nm_bts_sm_fsm.c @@ -57,7 +57,7 @@ static void st_op_disabled_notinstalled(struct osmo_fsm_inst *fi, uint32_t event struct gsm_bts_sm *site_mgr = (struct gsm_bts_sm *)fi->priv; struct gsm_bts *bts = gsm_bts_sm_get_bts(site_mgr); struct nm_statechg_signal_data *nsd; - struct gsm_nm_state *new_state; + const struct gsm_nm_state *new_state; switch (event) { case NM_EV_SW_ACT_REP: @@ -102,7 +102,7 @@ static void st_op_disabled_notinstalled(struct osmo_fsm_inst *fi, uint32_t event static void st_op_disabled_dependency(struct osmo_fsm_inst *fi, uint32_t event, void *data) { struct nm_statechg_signal_data *nsd; - struct gsm_nm_state *new_state; + const struct gsm_nm_state *new_state; switch (event) { case NM_EV_STATE_CHG_REP: @@ -142,7 +142,7 @@ static void st_op_disabled_offline_on_enter(struct osmo_fsm_inst *fi, uint32_t p static void st_op_disabled_offline(struct osmo_fsm_inst *fi, uint32_t event, void *data) { struct nm_statechg_signal_data *nsd; - struct gsm_nm_state *new_state; + const struct gsm_nm_state *new_state; switch (event) { case NM_EV_STATE_CHG_REP: @@ -173,7 +173,7 @@ static void st_op_disabled_offline(struct osmo_fsm_inst *fi, uint32_t event, voi static void st_op_enabled(struct osmo_fsm_inst *fi, uint32_t event, void *data) { struct nm_statechg_signal_data *nsd; - struct gsm_nm_state *new_state; + const struct gsm_nm_state *new_state; switch (event) { case NM_EV_STATE_CHG_REP: -- cgit v1.2.3