diff options
Diffstat (limited to 'src/network/shutdown.c')
-rw-r--r-- | src/network/shutdown.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/network/shutdown.c b/src/network/shutdown.c new file mode 100644 index 0000000..91950c8 --- /dev/null +++ b/src/network/shutdown.c @@ -0,0 +1,9 @@ +#include <sys/socket.h> +#include "syscall.h" +#include "socketcall.h" + +int shutdown(int fd, int how) +{ + unsigned long args[] = { fd, how }; + return syscall2(__NR_socketcall, SYS_SHUTDOWN, (long)args); +} |