<p>Sean Bright has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/11641">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">res_musiconhold: Use ast_pipe_nonblock() wrapper<br><br>Change-Id: Ib0a4b41e5ececbe633079e2d8c2b66c031d2d1f2<br>---<br>M res/res_musiconhold.c<br>1 file changed, 1 insertion(+), 5 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/41/11641/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/res/res_musiconhold.c b/res/res_musiconhold.c</span><br><span>index 85eb576..4b2e1fb 100644</span><br><span>--- a/res/res_musiconhold.c</span><br><span>+++ b/res/res_musiconhold.c</span><br><span>@@ -945,16 +945,12 @@</span><br><span> if (!(moh = ast_calloc(1, sizeof(*moh))))</span><br><span> return NULL;</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">- if (pipe(moh->pipe)) {</span><br><span style="color: hsl(120, 100%, 40%);">+ if (ast_pipe_nonblock(moh->pipe)) {</span><br><span> ast_log(LOG_WARNING, "Failed to create pipe: %s\n", strerror(errno));</span><br><span> ast_free(moh);</span><br><span> return NULL;</span><br><span> }</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">- /* Make entirely non-blocking */</span><br><span style="color: hsl(0, 100%, 40%);">- ast_fd_set_flags(moh->pipe[0], O_NONBLOCK);</span><br><span style="color: hsl(0, 100%, 40%);">- ast_fd_set_flags(moh->pipe[1], O_NONBLOCK);</span><br><span style="color: hsl(0, 100%, 40%);">-</span><br><span> moh->f.frametype = AST_FRAME_VOICE;</span><br><span> moh->f.subclass.format = cl->format;</span><br><span> moh->f.offset = AST_FRIENDLY_OFFSET;</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/11641">change 11641</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/+/11641"/><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-Change-Id: Ib0a4b41e5ececbe633079e2d8c2b66c031d2d1f2 </div>
<div style="display:none"> Gerrit-Change-Number: 11641 </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-MessageType: newchange </div>