<p>Sean Bright has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/17865">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">say.c: Prevent erroneous failures with 'say' family of functions.<br><br>A regression was introduced in ASTERISK~29531 that caused 'say'<br>functions to fail when file lists that would previously have<br>succeeded.<br><br>We now explicitly check for the empty string to restore the previous<br>behavior.<br><br>ASTERISK-29859 #close<br><br>Change-Id: Ia2e5769868e2792313c2d7c07996efe009c6f8d5<br>---<br>M main/say.c<br>1 file changed, 7 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/65/17865/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/main/say.c b/main/say.c</span><br><span>index 54aefe0..56e6b8d 100644</span><br><span>--- a/main/say.c</span><br><span>+++ b/main/say.c</span><br><span>@@ -180,6 +180,13 @@</span><br><span>  if (!filenames) {</span><br><span>            return -1;</span><br><span>   }</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+   /* No filenames to play? Return success so we don't hang up erroneously */</span><br><span style="color: hsl(120, 100%, 40%);">+        if (ast_str_strlen(filenames) == 0) {</span><br><span style="color: hsl(120, 100%, 40%);">+         ast_free(filenames);</span><br><span style="color: hsl(120, 100%, 40%);">+          return 0;</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span>  files = ast_str_buffer(filenames);</span><br><span> </span><br><span>       while ((fn = strsep(&files, "&"))) {</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/17865">change 17865</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/c/asterisk/+/17865"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 16 </div>
<div style="display:none"> Gerrit-Change-Id: Ia2e5769868e2792313c2d7c07996efe009c6f8d5 </div>
<div style="display:none"> Gerrit-Change-Number: 17865 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Sean Bright <sean@seanbright.com> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>