aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2018-12-11 01:59:25 +0100
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2018-12-17 14:39:16 +0000
commit5f1ac6dce630823373261e8ba5560b86ae74bee2 (patch)
tree4cfe05b0ba299d7659f6807d1764b247906b2e25
parent88063dd3684e79f508cf89086977426f4c98f443 (diff)
tweak comment to indicate sub_pres_vlr fsm as dead code
sub_pres_vlr_fsm_start() only ever has an effect if ms_not_reachable_flag == true. But there simply is no code that sets this flag. So sub_pres_vlr_fsm_start() is currently dead code. Also, examining the FSM, if it should ever be set to true, this would halt the LU/CM Service/Paging response, since the FSM would merely change its state without dispatching asynchronous messages. No chance of finishing. Short of dropping the code entirely, first just mark it. The point being that this models some FSM definition from 3GPP specs, and we have a couple other "if (0)" branches in the VLR... Change-Id: I198d442e9ed288f37c7d4e5ec87b82dc53114e99
-rw-r--r--src/libvlr/vlr_lu_fsm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libvlr/vlr_lu_fsm.c b/src/libvlr/vlr_lu_fsm.c
index 74a6939d0..a0cbcab92 100644
--- a/src/libvlr/vlr_lu_fsm.c
+++ b/src/libvlr/vlr_lu_fsm.c
@@ -271,7 +271,9 @@ static inline struct vlr_subscr *sub_pres_vlr_fi_priv(struct osmo_fsm_inst *fi)
return (struct vlr_subscr*)fi->priv;
}
-/* Note that the start event is dispatched right away, so in case the FSM immediately concludes from that
+/* THIS IS CURRENTLY DEAD CODE, SINCE WE NEVER SET vsub->ms_not_reachable_flag = true.
+ *
+ * Note that the start event is dispatched right away, so in case the FSM immediately concludes from that
* event, the created FSM struct may no longer be valid as it already deallocated again, and it may
* furthermore already have invoked the parent FSM instance's deallocation as well. Hence, instead of
* returning, store the created FSM instance address in *fi_p before dispatching the event. It is thus