diff options
Diffstat (limited to 'libpthread/linuxthreads')
-rw-r--r-- | libpthread/linuxthreads/sysdeps/unix/sysv/linux/execve.c | 54 | ||||
-rw-r--r-- | libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c | 4 |
2 files changed, 13 insertions, 45 deletions
diff --git a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/execve.c b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/execve.c index 9fa912b90..fb560762b 100644 --- a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/execve.c +++ b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/execve.c @@ -24,50 +24,18 @@ #include <sys/syscall.h> #include <bp-checks.h> -extern int __syscall_execve (const char *__unbounded file, - char *__unbounded const *__unbounded argv, - char *__unbounded const *__unbounded envp); -extern void __pthread_kill_other_threads_np (void); -weak_extern (__pthread_kill_other_threads_np) - +extern int __syscall_execve(const char *file, + char *const *argv, + char *const *envp); +extern void __pthread_kill_other_threads_np(void); +weak_extern(__pthread_kill_other_threads_np) int -__execve (file, argv, envp) - const char *file; - char *const argv[]; - char *const envp[]; +__execve(const char *file, char *const argv[], char *const envp[]) { - /* If this is a threaded application kill all other threads. */ - if (__pthread_kill_other_threads_np) - __pthread_kill_other_threads_np (); -#if __BOUNDED_POINTERS__ - { - char *const *v; - int i; - char *__unbounded *__unbounded ubp_argv; - char *__unbounded *__unbounded ubp_envp; - char *__unbounded *__unbounded ubp_v; - - for (v = argv; *v; v++) - ; - i = v - argv + 1; - ubp_argv = (char *__unbounded *__unbounded) alloca (sizeof (*ubp_argv) * i); - for (v = argv, ubp_v = ubp_argv; --i; v++, ubp_v++) - *ubp_v = CHECK_STRING (*v); - *ubp_v = 0; - - for (v = envp; *v; v++) - ; - i = v - envp + 1; - ubp_envp = (char *__unbounded *__unbounded) alloca (sizeof (*ubp_envp) * i); - for (v = envp, ubp_v = ubp_envp; --i; v++, ubp_v++) - *ubp_v = CHECK_STRING (*v); - *ubp_v = 0; - - return INLINE_SYSCALL (execve, 3, CHECK_STRING (file), ubp_argv, ubp_envp); - } -#else - return INLINE_SYSCALL (execve, 3, file, argv, envp); -#endif + /* If this is a threaded application kill all other threads. */ + if (__pthread_kill_other_threads_np) + __pthread_kill_other_threads_np(); + return INLINE_SYSCALL(execve, 3, file, argv, envp); } -weak_alias (__execve, execve) +weak_alias(__execve, execve) diff --git a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c index 3432125bb..71396f06a 100644 --- a/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c +++ b/libpthread/linuxthreads/sysdeps/unix/sysv/linux/sigwait.c @@ -26,8 +26,8 @@ #include <bp-checks.h> #include <bits/libc-lock.h> -extern int __syscall_rt_sigtimedwait (const sigset_t *__unbounded, siginfo_t *__unbounded, - const struct timespec *__unbounded, size_t); +extern int __syscall_rt_sigtimedwait (const sigset_t *, siginfo_t *, + const struct timespec *, size_t); /* Return any pending signal or wait for one for the given time. */ |