From 1c55d2e868d6f7d22da5fa986a0359ede8793178 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Fri, 5 Nov 1999 19:38:37 +0000 Subject: Split unistd.c file into sysconf.c and sleep.c. --- cpukit/posix/src/sysconf.c | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 cpukit/posix/src/sysconf.c (limited to 'cpukit/posix/src/sysconf.c') diff --git a/cpukit/posix/src/sysconf.c b/cpukit/posix/src/sysconf.c new file mode 100644 index 0000000000..8d930ce33c --- /dev/null +++ b/cpukit/posix/src/sysconf.c @@ -0,0 +1,41 @@ +/* + * $Id$ + */ + +#include +#include + +#include + + +/* + * 3.4.3 Delay Process Execution, P1003.1b-1993, p. 81 + */ + +unsigned int sleep( + unsigned int seconds +) +{ + /* XXX can we get away with this implementation? */ + struct timespec tp; + struct timespec tm; + + tp.tv_sec = seconds; + tp.tv_nsec = 0; + + nanosleep( &tp, &tm ); + + return tm.tv_sec; /* seconds remaining */ +} + +/*PAGE + * + * 4.8.1 Get Configurable System Variables, P1003.1b-1993, p. 95 + */ + +long sysconf( + int name +) +{ + return POSIX_NOT_IMPLEMENTED(); +} -- cgit v1.2.3