diff options
author | Ulrich Drepper <drepper@redhat.com> | 2002-12-17 06:52:45 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2002-12-17 06:52:45 +0000 |
commit | 3ca97e8f0f08c85aecc08f5f171e46729e04911d (patch) | |
tree | 6a5d1517f52d649f0a46ba6dbf6bf1bf55b072d2 /sysdeps/posix/system.c | |
parent | 26a026b94036e2e2a41a6693327d796cc82bdacd (diff) | |
download | glibc-3ca97e8f0f08c85aecc08f5f171e46729e04911d.zip glibc-3ca97e8f0f08c85aecc08f5f171e46729e04911d.tar.gz glibc-3ca97e8f0f08c85aecc08f5f171e46729e04911d.tar.bz2 |
Update.
* sysdeps/posix/system.c (do_system): Add support for installation
of cancellation handlers.
* sysdeps/unix/sysv/linux/i386/system.c: New file.
* stdlib/Makefile (tests): Add tst-system.
* stdlib/tst-system.c: New file.
Diffstat (limited to 'sysdeps/posix/system.c')
-rw-r--r-- | sysdeps/posix/system.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/sysdeps/posix/system.c b/sysdeps/posix/system.c index bca1c2e..0885280 100644 --- a/sysdeps/posix/system.c +++ b/sysdeps/posix/system.c @@ -112,7 +112,15 @@ do_system (const char *line) } } +#ifdef CLEANUP_HANDLER + CLEANUP_HANDLER; +#endif + +#ifdef FORK + pid = FORK (); +#else pid = __fork (); +#endif if (pid == (pid_t) 0) { /* Child side. */ @@ -158,6 +166,10 @@ do_system (const char *line) #endif } +#ifdef CLEANUP_HANDLER + CLEANUP_RESET; +#endif + save = errno; DO_LOCK (); if ((SUB_REF () == 0 |