From 13a9765877d78ed9e1779dab2a82012fbb36eab8 Mon Sep 17 00:00:00 2001 From: Ole André Vadla Ravnås Date: Fri, 2 Nov 2007 21:16:09 +0000 Subject: Fix includes for MSVC and GLib-2.14.0 (#492388). MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Original commit message from CVS: Patch by: Ole André Vadla Ravnås * configure.ac: * gst/udp/gstdynudpsink.c: * gst/udp/gstdynudpsink.h: * gst/udp/gstmultiudpsink.c: * gst/udp/gstmultiudpsink.h: * gst/udp/gstudpsink.c: * gst/udp/gstudpsink.h: Fix includes for MSVC and GLib-2.14.0 (#492388). * gst/udp/gstudpsrc.c: (gst_udpsrc_start): No more pipe define since GLib-2.14.0, need to use _pipe() directly. --- gst/udp/gstudpsrc.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'gst/udp/gstudpsrc.c') diff --git a/gst/udp/gstudpsrc.c b/gst/udp/gstudpsrc.c index d547fea1..8964f837 100644 --- a/gst/udp/gstudpsrc.c +++ b/gst/udp/gstudpsrc.c @@ -120,9 +120,15 @@ #endif #include "gstudpsrc.h" +#ifdef HAVE_UNISTD_H #include +#endif #include +#if defined _MSC_VER && (_MSC_VER >= 1400) +#include +#endif + #include #ifdef G_OS_WIN32 typedef int socklen_t; @@ -711,8 +717,8 @@ gst_udpsrc_start (GstBaseSrc * bsrc) GST_DEBUG_OBJECT (src, "creating pipe"); /* This should work on UNIX too. PF_UNIX sockets replaced with pipe */ - /* pipe( CONTROL_SOCKETS(src) ) */ - if ((ret = pipe (CONTROL_SOCKETS (src))) < 0) + /* pipe( CONTROL_SOCKETS(src), 4096, _O_BINARY ) */ + if ((ret = _pipe (CONTROL_SOCKETS (src), 4096, _O_BINARY)) < 0) goto no_socket_pair; #else GST_DEBUG_OBJECT (src, "creating socket pair"); -- cgit