home *** CD-ROM | disk | FTP | other *** search
- #include <syscall.h>
- #include <sys/socket.h>
- #include <sys/socketcall.h>
-
- static inline
- _syscall2(long,socketcall,int,call,unsigned long *,args);
-
- int
- socketpair(int family, int type, int protocol, int sockvec[2])
- {
- unsigned long args[4];
-
- args[0] = family;
- args[1] = type;
- args[2] = protocol;
- args[3] = (unsigned long)sockvec;
- return socketcall(SYS_SOCKETPAIR, args);
- }
-