Check-in Number:
|
2789 | |
Date: |
2002-Nov-09 12:30:14 (local)
2002-Nov-09 11:30:14 (UTC) |
User: | rse |
Branch: | |
Comment: |
Added soft syscall mapping for nanosleep(3) and
usleep(3) functions also to the Pthread API. |
Tickets: |
|
Inspections: |
|
Files: |
|
ossp-pkg/pth/ChangeLog 1.598 -> 1.599
--- ChangeLog 2002/11/08 20:27:28 1.598
+++ ChangeLog 2002/11/09 11:30:14 1.599
@@ -19,6 +19,12 @@
/ __/ | |_| |
__|_____(_)___/_________________________________________________________
+ Changes between 2.0b1 and 2.0b2 (08-Nov-2002 to xx-Nov-2002)
+
+ *) Added soft syscall mapping for nanosleep(3) and
+ usleep(3) functions also to the Pthread API.
+ [Ralf S. Engelschall]
+
Changes between 2.0b0 and 2.0b1 (07-Nov-2002 to 08-Nov-2002)
*) Make pth_poll(3) more compliant to POSIX.1-2001/SUSv3 poll(2).
|
|
ossp-pkg/pth/pthread.c 1.62 -> 1.63
--- pthread.c 2002/11/05 19:39:09 1.62
+++ pthread.c 2002/11/09 11:30:15 1.63
@@ -1056,6 +1056,18 @@
return pth_system(cmd);
}
+int __pthread_nanosleep(const struct timespec *rqtp, struct timespec *rmtp)
+{
+ pthread_initialize();
+ return pth_nanosleep(rqtp, rmtp);
+}
+
+int __pthread_usleep(unsigned int sec)
+{
+ pthread_initialize();
+ return pth_usleep(sec);
+}
+
int __pthread_sigwait(const sigset_t *set, int *sig)
{
pthread_initialize();
|
|
ossp-pkg/pth/pthread.h.in 1.65 -> 1.66
--- pthread.h.in 2002/11/03 16:31:34 1.65
+++ pthread.h.in 2002/11/09 11:30:15 1.66
@@ -493,6 +493,8 @@
extern pid_t __pthread_fork(void);
extern unsigned int __pthread_sleep(unsigned int);
+extern int __pthread_nanosleep(const struct timespec *, struct timespec *);
+extern int __pthread_usleep(unsigned int);
extern int __pthread_system(const char *);
extern int __pthread_sigwait(const sigset_t *, int *);
extern pid_t __pthread_waitpid(pid_t, int *, int);
@@ -514,6 +516,8 @@
#if _POSIX_THREAD_SYSCALL_SOFT && !defined(_PTHREAD_PRIVATE)
#define fork __pthread_fork
#define sleep __pthread_sleep
+#define nanosleep __pthread_nanosleep
+#define usleep __pthread_usleep
#define system __pthread_system
#define sigwait __pthread_sigwait
#define waitpid __pthread_waitpid
|
|