<p>Corey Farrell has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/7679">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">app_festival: Fix fd leak on connection failure.<br><br>Change-Id: If5efaddcf735ff7d17e55c36cc1388946cee9e0f<br>---<br>M apps/app_festival.c<br>1 file changed, 2 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/79/7679/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/apps/app_festival.c b/apps/app_festival.c<br>index 3e2e020..715437e 100644<br>--- a/apps/app_festival.c<br>+++ b/apps/app_festival.c<br>@@ -403,6 +403,7 @@<br> if (serverhost == NULL) {<br> ast_log(LOG_WARNING, "festival_client: gethostbyname failed\n");<br> ast_config_destroy(cfg);<br>+ close(fd);<br> return -1;<br> }<br> memmove(&serv_addr.sin_addr, serverhost->h_addr, serverhost->h_length);<br>@@ -414,6 +415,7 @@<br> if (connect(fd, (struct sockaddr *)&serv_addr, sizeof(serv_addr)) != 0) {<br> ast_log(LOG_WARNING, "festival_client: connect to server failed\n");<br> ast_config_destroy(cfg);<br>+ close(fd);<br> return -1;<br> }<br> <br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/7679">change 7679</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/7679"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: If5efaddcf735ff7d17e55c36cc1388946cee9e0f </div>
<div style="display:none"> Gerrit-Change-Number: 7679 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Corey Farrell <git@cfware.com> </div>