<p>Richard Mudgett <strong>posted comments</strong> on this change.</p><p><a href="https://gerrit.asterisk.org/6380">View Change</a></p><p>Patch set 1:</p><p style="white-space: pre-wrap; word-wrap: break-word;">Patch will work as is.  -1 just so comments are noticed.</p><p>(2 comments)</p><ul style="list-style: none; padding-left: 20px;"><li><p><a href="https://gerrit.asterisk.org/#/c/6380/1/main/rtp_engine.c">File main/rtp_engine.c:</a></p><ul style="list-style: none; padding-left: 20px;"><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/6380/1/main/rtp_engine.c@2114">Patch Set #1, Line 2114:</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;">         release_cfg_string(&dtls_cfg->certfile);<br>               if (!ast_strlen_zero(value) && !ast_file_is_readable(value)) {<br>                        ast_log(LOG_ERROR, "%s file %s does not exist or is not readable\n", name, value);<br>                  return -1;<br>            }<br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">It would be just as effective and simpler to move the ast_free() to after the validation check.  If the new value is invalid then you still have the old value in place as a fallback.</p></li><li><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/6380/1/main/rtp_engine.c@2128">Patch Set #1, Line 2128:</a> <code style="font-family:monospace,monospace">              release_cfg_string(&dtls_cfg->cipher);</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">This change isn't really necessary.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.asterisk.org/6380">change 6380</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/6380"/><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: I097b81734ef730f8603c0b972909d212a3a5cf89 </div>
<div style="display:none"> Gerrit-Change-Number: 6380 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Sean Bright <sean.bright@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 </div>
<div style="display:none"> Gerrit-Reviewer: Richard Mudgett <rmudgett@digium.com> </div>
<div style="display:none"> Gerrit-Comment-Date: Fri, 01 Sep 2017 21:55:31 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>