Neels Hofmeyr has submitted this change and it was merged. ( https://gerrit.osmocom.org/12234 )
Change subject: tweak comment to indicate sub_pres_vlr fsm as dead code ...................................................................... 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 --- M src/libvlr/vlr_lu_fsm.c 1 file changed, 3 insertions(+), 1 deletion(-) Approvals: Neels Hofmeyr: Looks good to me, approved Stefan Sperling: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/src/libvlr/vlr_lu_fsm.c b/src/libvlr/vlr_lu_fsm.c index 74a6939..a0cbcab 100644 --- a/src/libvlr/vlr_lu_fsm.c +++ b/src/libvlr/vlr_lu_fsm.c @@ -271,7 +271,9 @@ 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 -- To view, visit https://gerrit.osmocom.org/12234 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-msc Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: I198d442e9ed288f37c7d4e5ec87b82dc53114e99 Gerrit-Change-Number: 12234 Gerrit-PatchSet: 4 Gerrit-Owner: Neels Hofmeyr <nhofm...@sysmocom.de> Gerrit-Reviewer: Jenkins Builder (1000002) Gerrit-Reviewer: Neels Hofmeyr <nhofm...@sysmocom.de> Gerrit-Reviewer: Stefan Sperling <s...@stsp.name> Gerrit-CC: Max <msur...@sysmocom.de> Gerrit-CC: Pau Espin Pedrol <pes...@sysmocom.de>