some coverity fixes.
[minix.git] / lib / libc / sys-minix / pipe.c
blob9f883885ce79f7c966695672cec821a051f8a009
1 #include <sys/cdefs.h>
2 #include "namespace.h"
3 #include <lib.h>
5 #include <unistd.h>
7 #ifdef __weak_alias
8 __weak_alias(pipe, _pipe)
9 #endif
11 int pipe(fild)
12 int fild[2];
14 message m;
16 if (_syscall(VFS_PROC_NR, PIPE, &m) < 0) return(-1);
17 fild[0] = m.m1_i1;
18 fild[1] = m.m1_i2;
19 return(0);