[vlc-devel] commit: httpd: fix error handling path ( Rémi Denis-Courmont )

git version control git at videolan.org
Wed Jan 14 21:21:32 CET 2009


vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Wed Jan 14 21:58:51 2009 +0200| [e9cbd35ba6d5f229bfae9c1c1f0b9559214703a7] | committer: Rémi Denis-Courmont 

httpd: fix error handling path

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e9cbd35ba6d5f229bfae9c1c1f0b9559214703a7
---

 src/network/httpd.c |   15 ++++++---------
 1 files changed, 6 insertions(+), 9 deletions(-)

diff --git a/src/network/httpd.c b/src/network/httpd.c
index 4a1ddd0..f913608 100644
--- a/src/network/httpd.c
+++ b/src/network/httpd.c
@@ -1073,15 +1073,6 @@ httpd_host_t *httpd_TLSHostNew( vlc_object_t *p_this, const char *psz_hostname,
     if (host == NULL)
         goto error;
 
-    vlc_object_lock( host );
-    if( vlc_object_waitpipe( VLC_OBJECT( host ) ) == -1 )
-    {
-        msg_Err( host, "signaling pipe error: %m" );
-        vlc_object_unlock( host );
-        goto error;
-    }
-    vlc_object_unlock( host );
-
     host->httpd = httpd;
     vlc_mutex_init( &host->lock );
     host->i_ref = 1;
@@ -1094,6 +1085,12 @@ httpd_host_t *httpd_TLSHostNew( vlc_object_t *p_this, const char *psz_hostname,
     }
     for (host->nfd = 0; host->fds[host->nfd] != -1; host->nfd++);
 
+    if( vlc_object_waitpipe( VLC_OBJECT( host ) ) == -1 )
+    {
+        msg_Err( host, "signaling pipe error: %m" );
+        goto error;
+    }
+
     host->i_port = i_port;
     host->psz_hostname = psz_host;
 




More information about the vlc-devel mailing list