mirror of
https://github.com/9fans/plan9port.git
synced 2025-01-27 11:52:03 +00:00
2277c5d7bb
Lots of new code imported.
15 lines
320 B
C
15 lines
320 B
C
#include <u.h>
|
|
#define NOPLAN9DEFINES
|
|
#include <libc.h>
|
|
#include <sys/socket.h>
|
|
|
|
/*
|
|
* We use socketpair to get a two-way pipe.
|
|
* The pipe still doesn't preserve message boundaries.
|
|
* Worse, it cannot be reopened via /dev/fd/NNN on Linux.
|
|
*/
|
|
int
|
|
p9pipe(int fd[2])
|
|
{
|
|
return socketpair(AF_UNIX, SOCK_STREAM, 0, fd);
|
|
}
|