added pause() (kernel support is lacking though)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14130 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2005-09-08 13:06:49 +00:00
parent 96e6579454
commit 04b831a692
2 changed files with 23 additions and 0 deletions

View File

@ -19,6 +19,7 @@ KernelMergeObject posix_unistd.o :
mknod.c
mount.c
open.c
pause.c
pipe.c
process.c
read.c

View File

@ -0,0 +1,22 @@
/*
* Copyright (c) 2005, Haiku Project. All rights reserved.
* Distributed under the terms of the Haiku license.
*
* Author(s):
* Jérôme Duval
*/
#include <errno.h>
#include <signal.h>
#include <syscalls.h>
#include <unistd.h>
int
pause()
{
sigset_t mask;
sigemptyset(&mask);
errno = _kern_sigsuspend(&mask);
return -1;
}