<p>Richard Mudgett <strong>posted comments</strong> on this change.</p><p><a href="https://gerrit.asterisk.org/7710">View Change</a></p><p>Patch set 6:</p><p>(10 comments)</p><ul style="list-style: none; padding-left: 20px;"><li><p><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c">File res/res_pjsip/pjsip_options.c:</a></p><ul style="list-style: none; padding-left: 20px;"><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@338">Patch Set #6, Line 338:</a> <code style="font-family:monospace,monospace"> return status_map[status];</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Do we want:</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@343">Patch Set #6, Line 343:</a> <code style="font-family:monospace,monospace"> return short_status_map[status];</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Do we want:</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@472">Patch Set #6, Line 472:</a> <code style="font-family:monospace,monospace"> if (!sip_options_contact_statuses) {</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Additional note: I'm also assuming this can be hit by a race condition. If</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@472">Patch Set #6, Line 472:</a> <code style="font-family:monospace,monospace"> if (!sip_options_contact_statuses) {</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">This is concerning. Why can't we fix the module initialization order to al</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@1363">Patch Set #6, Line 1363:</a> <code style="font-family:monospace,monospace"> ast_log(LOG_ERROR, "Unable to schedule qualify for contacts of AOR '%s'\n",</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Is it not appropriate to return -1 here?</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">It doesn't really matter. We have done everything but get the timer started and nobody cares about the return value because they cannot do anything about it anyway. I have changed the function to return void.</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@1530">Patch Set #6, Line 1530:</a> <code style="font-family:monospace,monospace"> AST_VECTOR_APPEND(&task_data->aor_options->compositors,</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">AST_VECTOR_APPEND could fail, leaking a reference to task_data->endpoint_st</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@1750">Patch Set #6, Line 1750:</a> <code style="font-family:monospace,monospace"> return 0;</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Error message or return -1?</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">The return value doesn't matter and we have already had a malloc failure error logged.</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@1960">Patch Set #6, Line 1960:</a> <code style="font-family:monospace,monospace"> return 0;</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Error message or return -1?</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">The return value doesn't matter and we have already had a malloc failure error logged.</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@2098">Patch Set #6, Line 2098:</a> <code style="font-family:monospace,monospace"> ast_log(LOG_ERROR, "Unable to schedule qualify for contacts of AOR '%s'\n",</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">return -1?</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">The return value doesn't matter.</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/7710/6/res/res_pjsip/pjsip_options.c@2212">Patch Set #6, Line 2212:</a> <code style="font-family:monospace,monospace"> ao2_cleanup(task_data->aor_options);</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Nit: task_data->aor_options is NULL.</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.asterisk.org/7710">change 7710</a>. To unsubscribe, 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/7710"/><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: I6a5ebbfca9001dfe933eaeac4d3babd8d2e6f082 </div>
<div style="display:none"> Gerrit-Change-Number: 7710 </div>
<div style="display:none"> Gerrit-PatchSet: 6 </div>
<div style="display:none"> Gerrit-Owner: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Corey Farrell <git@cfware.com> </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Richard Mudgett <rmudgett@digium.com> </div>
<div style="display:none"> Gerrit-Comment-Date: Fri, 27 Apr 2018 22:14:01 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>