Browse Source

Netbios: provide a replacement for pipe for Windows

Jean-Baptiste Kempf 9 years ago
parent
commit
3abb031c79
1 changed files with 7 additions and 0 deletions
  1. 7 0
      src/netbios_ns.c

+ 7 - 0
src/netbios_ns.c

@@ -152,6 +152,13 @@ error:
     return 0;
     return 0;
 }
 }
 
 
+#ifdef _WIN32
+static inline int pipe(int fds[2])
+{
+    return _pipe(fds, 32768, O_NOINHERIT | O_BINARY);
+}
+#endif
+
 static int    ns_open_abort_pipe(netbios_ns *ns)
 static int    ns_open_abort_pipe(netbios_ns *ns)
 {
 {
     int flags;
     int flags;