<p style="white-space: pre-wrap; word-wrap: break-word;">(ensure all messages are sent)</p><p><a href="https://gerrit.osmocom.org/c/osmo-mgw/+/18745">View Change</a></p><p>2 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/c/osmo-mgw/+/18745/1//COMMIT_MSG">Commit Message:</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-mgw/+/18745/1//COMMIT_MSG@10">Patch Set #1, Line 10:</a> <code style="font-family:monospace,monospace">correct. Lets add an endpoint name generator function that derives a</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Let's</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li></ul></li><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/c/osmo-mgw/+/18745/1/src/libosmo-mgcp/mgcp_endp.c">File src/libosmo-mgcp/mgcp_endp.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-mgw/+/18745/1/src/libosmo-mgcp/mgcp_endp.c@87">Patch Set #1, Line 87:</a> <code style="font-family:monospace,monospace">          gen_e1_epname(ep_name_buf, trunk->trunk_nr, index / 14, index % 14);</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">So you'll be in the end crafting an index value to pass it to mgcp_endp_alloc(), to then uncraft it  […]</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">When the trunk is allocated all it knows is how many endpoints it has to allocate. The index is just for the moment of allocation so that the endp alloc function can generate the name.</p><p style="white-space: pre-wrap; word-wrap: break-word;">I had the name generation in mgcp_trunk.c before but I think that the "knowlege" on how the name is generated should only be in mgcp_endp.c. We also remove complexity, the trunk no longer has to distinguish between the E1 and virtual when generating the name.</p><p style="white-space: pre-wrap; word-wrap: break-word;">An alternate solution would be to let mgcp_endp_alloc() allocate all endpoints, then the index would not have to passed as a parameter.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-mgw/+/18745">change 18745</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-mgw/+/18745"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-mgw </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I70e0c3f96aa3947165f9926666815ee5614c8f57 </div>
<div style="display:none"> Gerrit-Change-Number: 18745 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </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: dexter <pmaier@sysmocom.de> </div>
<div style="display:none"> Gerrit-CC: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-Comment-Date: Tue, 09 Jun 2020 17:00:15 +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"> Gerrit-MessageType: comment </div>