<p style="white-space: pre-wrap; word-wrap: break-word;">TBH I don't like this API, I think it's too specific.</p><p style="white-space: pre-wrap; word-wrap: break-word;">I'd rather add a free_cb, which is more common for readers and more generic (can be reused for other purposes):</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><br>void mycb(fi, pdata)<br>{<br> bool *freed = (bool*) pdata;<br> freed = true;<br>}<br>void event_action()<br>{<br>bool freed = false;<br>osmo_fsm_free_cb_set(fi, mycb, freed);<br>osmo_fsm_inst(....)<br>if (!freed)<br>    return;<br>osmo_fsm_inst(....)<br>}<br></pre><p><a href="https://gerrit.osmocom.org/c/libosmocore/+/15660">View Change</a></p><ul style="list-style: none; padding: 0;"></ul><p>To view, visit <a href="https://gerrit.osmocom.org/c/libosmocore/+/15660">change 15660</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/libosmocore/+/15660"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: libosmocore </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I4d8306488506c60b4c2fc1c4cb3ac04654db9c43 </div>
<div style="display:none"> Gerrit-Change-Number: 15660 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: neels <nhofmeyr@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-CC: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-Comment-Date: Wed, 02 Oct 2019 22:21:21 +0000 </div>
<div style="display:none"> Gerrit-HasComments: No </div>
<div style="display:none"> Gerrit-Has-Labels: No </div>
<div style="display:none"> Gerrit-MessageType: comment </div>