<p>Patch set 4:<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.asterisk.org/10246">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.asterisk.org/#/c/10246/4/res/res_rtp_asterisk.c">File res/res_rtp_asterisk.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.asterisk.org/#/c/10246/4/res/res_rtp_asterisk.c@191">Patch Set #4, Line 191:</a> <code style="font-family:monospace,monospace">static int strict_rtp_test_event = 1;</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">If TEST_FRAMEWORK is not defined this will cause a not used warning/error.</p><p style="white-space: pre-wrap; word-wrap: break-word;">Since this is only used in one place, see my comment where it is used.</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/10246/4/res/res_rtp_asterisk.c@5532">Patch Set #4, Line 5532:</a> </p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;"><pre style="font-family: monospace,monospace; white-space: pre-wrap;">#ifdef TEST_FRAMEWORK<br>                if (strict_rtp_test_event) {<br>                  ast_test_suite_event_notify("STRICT_RTP_CLOSED", "Source: %s",<br>                            ast_sockaddr_stringify(&addr));<br>                   strict_rtp_test_event = 0; /* Only run this event once to prevent possible spam */<br>            }<br>#endif<br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">This can be surrounded by curlies to declare strict_rtp_test_event here in one place.</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">#ifdef TEST_FRAMEWORK<br>    {<br>        static int strict_rtp_test_event = 1;</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">        if (strict_rtp_test_event) {<br>            strict_rtp_test_event = 0;<br>            ast_test_suite_event_notify(...);<br>        }<br>    }<br>#endif</pre></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/10246/4/res/res_rtp_asterisk.c@6678">Patch Set #4, Line 6678:</a> </p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;"><pre style="font-family: monospace,monospace; white-space: pre-wrap;">              strictrtp = ast_true(s);<br>              if (!strcasecmp(s, "seqno")) {<br>                      strictrtp = STRICT_RTP_SEQNO;<br>         } else if (strictrtp == -1) {<br>                 /* Stick to enum values for consistency */<br>                    strictrtp = STRICT_RTP_YES;<br>           }<br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Better to only set strictrtp to the correct enum value rather than having momentary non-enum values:</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">if (ast_true(s)) {<br>   strictrtp = STRICT_RTP_YES;<br>} else if (!strcasecmp(s, "seqno")) {<br>   strictrtp = STRICT_RTP_SEQNO;<br>} else {<br>   strictrtp = STRICT_RTP_NO;<br>}</pre></li></ul></li></ul><p>To view, visit <a href="https://gerrit.asterisk.org/10246">change 10246</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.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.asterisk.org/10246"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: comment </div>
<div style="display:none"> Gerrit-Change-Id: I8a42b8d193673899c8fc22fe7f98ea87df89be71 </div>
<div style="display:none"> Gerrit-Change-Number: 10246 </div>
<div style="display:none"> Gerrit-PatchSet: 4 </div>
<div style="display:none"> Gerrit-Owner: Benjamin Keith Ford <bford@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Benjamin Keith Ford <bford@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 (1000185) </div>
<div style="display:none"> Gerrit-Reviewer: Richard Mudgett <rmudgett@digium.com> </div>
<div style="display:none"> Gerrit-Comment-Date: Wed, 26 Sep 2018 15:28:59 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-HasLabels: Yes </div>