<p>neels <strong>uploaded patch set #2</strong> to this change.</p><p><a href="https://gerrit.osmocom.org/c/osmo-msc/+/15947">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">add sdp_msg API: SDP parsing/composition<br><br>Rationale: in order to add full SDP to the MNCC protocol (upcoming patch<br>I8c3b2de53ffae4ec3a66b9dabf308c290a2c999f), we need to parse and compose SDP<br>messages. Obviously, libosmo-mgcp-client already contains similar code, but<br>that is unfortunately heavily glued to the actual MGCP implementation. The<br>simplest solution is to create this separate implementation, copy-pasting from<br>the existing libosmo-mgcp-client code as is convenient.<br><br>Various foo_name() functions are implemented for the sdp_msg API.<br>Each is:<br>a) implemented as foo_name_buf(buf, len, val),<br>b) wrapped as foo_name_c(ctx, val)<br>c) and as foo_name(val), a convienience variant using OTC_SELECT.<br><br>(a) foo_name_buf() uses osmo_strbuf to write to a fixed-size caller provided<br>buffer: osmo_strbuf is most convenient to implement optional parts / loops.<br><br>(b) foo_name_c() uses a caller-provided talloc ctx to allocate such buffer;<br>implemented using a generalized NAME_C_IMPL(func_buf, arg) macro, which calls<br>func with an initial size buffer, and reallocates if more space is needed.<br><br>(c) foo_name() then calls foo_name_c() with the OTC_SELECT context (we know that<br>msc_main.c uses osmo_select_main_ctx()), implemented using a generalized<br>NAME_IMPL() macro, and returns "ERROR" on failure instead of NULL.<br><br>Change-Id: If3ce23cd5bab15e2ab4c52ef3e4c75979dffe931<br>---<br>M configure.ac<br>M include/osmocom/msc/Makefile.am<br>A include/osmocom/msc/sdp_msg.h<br>M src/libmsc/Makefile.am<br>A src/libmsc/sdp_msg.c<br>M tests/Makefile.am<br>A tests/sdp_msg/Makefile.am<br>A tests/sdp_msg/sdp_msg_test.c<br>A tests/sdp_msg/sdp_msg_test.err<br>A tests/sdp_msg/sdp_msg_test.ok<br>M tests/testsuite.at<br>11 files changed, 1,846 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/47/15947/2</pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-msc/+/15947">change 15947</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-msc/+/15947"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-msc </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: If3ce23cd5bab15e2ab4c52ef3e4c75979dffe931 </div>
<div style="display:none"> Gerrit-Change-Number: 15947 </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-Reviewer: neels <nhofmeyr@sysmocom.de> </div>
<div style="display:none"> Gerrit-CC: laforge <laforge@osmocom.org> </div>
<div style="display:none"> Gerrit-CC: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: newpatchset </div>