<p style="white-space: pre-wrap; word-wrap: break-word;">(in general, I think you can still drop a lot of comments ... if you can be bothered)</p><p>Patch set 11:<span style="border-radius: 3px; display: inline-block; margin: 0 2px; padding: 4px;background-color: #ffd4d4;">Code-Review -1</span></p><p><a href="https://gerrit.osmocom.org/11920">View Change</a></p><p>8 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_08.c">File src/libmsc/gsm_04_08.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/11920/11/src/libmsc/gsm_04_08.c@1802">Patch Set #11, Line 1802:</a> <code style="font-family:monospace,monospace">        /* GSM 04.11 code implementing MT SMS */</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">(a comment is always about "code implementing")</p></li></ul></li><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c">File src/libmsc/gsm_04_11.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/11920/11/src/libmsc/gsm_04_11.c@162">Patch Set #11, Line 162:</a> <code style="font-family:monospace,monospace">            if (sms != NULL) { /* gsm411_send_rp_data() doesn't set trans->sms.sms */</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">put the "doesn't set" above the 'if', and the 'Notify...' inside the 'if {' body</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c@1147">Patch Set #11, Line 1147:</a> <code style="font-family:monospace,monospace"></code></p><p style="white-space: pre-wrap; word-wrap: break-word;">hmm, I sort of expected a TLV structure, but there are no Ts... too late for that I guess.</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c@1148">Patch Set #11, Line 1148:</a> <code style="font-family:monospace,monospace">        /* Encode RP-DA length */</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">OA?</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c@1154">Patch Set #11, Line 1154:</a> <code style="font-family:monospace,monospace">    memcpy(ptr, sm_rp_oa, sm_rp_oa_len);</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">Rather use msgb_lv_put()?</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c@1158">Patch Set #11, Line 1158:</a> <code style="font-family:monospace,monospace">   ptr[0] = 0x00;</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">msgb_put_u8()? msgb_v_put()?</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c@1166">Patch Set #11, Line 1166:</a> <code style="font-family:monospace,monospace">      memcpy(ptr, sm_rp_ud, sm_rp_ud_len);</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">msgb_lv_put()?</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11920/11/src/libmsc/gsm_04_11.c@1170">Patch Set #11, Line 1170:</a> <code style="font-family:monospace,monospace">      return gsm411_rp_sendmsg(&trans->sms.smr_inst, msg,</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">API wise it would be better to have separate functions that encode and send. I often faced inflexibility with code that cannot encode without also sending, for example during unit testing.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.osmocom.org/11920">change 11920</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/11920"/><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-MessageType: comment </div>
<div style="display:none"> Gerrit-Change-Id: I57357982ca0e51f6722c24a4aa1d0fb3e6caef88 </div>
<div style="display:none"> Gerrit-Change-Number: 11920 </div>
<div style="display:none"> Gerrit-PatchSet: 11 </div>
<div style="display:none"> Gerrit-Owner: Vadim Yanitskiy <axilirator@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder (1000002) </div>
<div style="display:none"> Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Vadim Yanitskiy <axilirator@gmail.com> </div>
<div style="display:none"> Gerrit-CC: Stefan Sperling <stsp@stsp.name> </div>
<div style="display:none"> Gerrit-Comment-Date: Sat, 05 Jan 2019 04:28:14 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-HasLabels: Yes </div>