<p><a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513">View Change</a></p><p>3 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513/5/src/common/abis.c">File src/common/abis.c:</a></p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513/5/src/common/abis.c@144">Patch Set #5, Line 144:</a> <code style="font-family:monospace,monospace">                /* In some implementations the user may specify a BSC host via commandline switch. If this is the case</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">This is related to osmo-bts-omldummy, this implementation has a commandline switch to specify the BS […]</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Yes please, better do that. Create an entry for the llist in osmo-bts-omldummy specific code.</p></li></ul></li><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513/6/src/common/abis.c">File src/common/abis.c:</a></p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513/6/src/common/abis.c@130">Patch Set #6, Line 130:</a> <code style="font-family:monospace,monospace">                osmo_fsm_inst_state_chg(fi, ABIS_LINK_ST_FAILED, 0, 0);</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">maybe "ABIS_LINK_ST_CONN_DROPPED" would be more meaningful, since it's actually what happens when you are in that state. "FAILED" seems a bit too generic.</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513/6/src/common/abis.c@147">Patch Set #6, Line 147:</a> <code style="font-family:monospace,monospace">       if (!llist_contains(&bts->bsc_oml_hosts, priv->bsc_oml_host))</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">you are potentially accessing already freed memory here, since priv->bsc_oml_host is a pointer pointing to memory which may have been free by VTY. What you need to do is, in the VTY code, when removing the entry, change "priv->bsc_oml_host" to the next item in the list.</p><p style="white-space: pre-wrap; word-wrap: break-word;">The best may be actually sending an event to the FSM before freeing the memory: "dispatch(EV_OML_HOST_REMOVED, bsc_oml_host);" and update the llist internally in the FSM.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-bts/+/24513">change 24513</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/osmo-bts/+/24513"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-bts </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I205f68a3a7f35fee4c38a7cfba2b014237df2727 </div>
<div style="display:none"> Gerrit-Change-Number: 24513 </div>
<div style="display:none"> Gerrit-PatchSet: 6 </div>
<div style="display:none"> Gerrit-Owner: dexter <pmaier@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-Reviewer: laforge <laforge@osmocom.org> </div>
<div style="display:none"> Gerrit-CC: fixeria <vyanitskiy@sysmocom.de> </div>
<div style="display:none"> Gerrit-CC: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-Comment-Date: Tue, 29 Jun 2021 14:50:00 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-Has-Labels: No </div>
<div style="display:none"> Comment-In-Reply-To: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Comment-In-Reply-To: dexter <pmaier@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: comment </div>