Use gnulib's sys/wait.h replacement.
authorBruno Haible <bruno@clisp.org>
Mon, 20 Oct 2008 22:58:48 +0000 (00:58 +0200)
committerBruno Haible <bruno@clisp.org>
Mon, 20 Oct 2008 23:01:26 +0000 (01:01 +0200)
ChangeLog
modules/posix_spawnp-tests
tests/test-posix_spawn1.c
tests/test-posix_spawn2.c

index 2cf7e62213e0e1552a6ee18947ce64c4a394eea9..2849469c4faa4e3c8d3077ada455428caeccb38f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2008-10-20  Bruno Haible  <bruno@clisp.org>
+
+       * modules/posix_spawnp-tests (Depends-on): Add sys_wait.
+       * tests/test-posix_spawn1.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
+       WIFSIGNALED, WIFEXITED, WIFSTOPPED): Remove fallback definitions.
+       * tests/test-posix_spawn2.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
+       WIFSIGNALED, WIFEXITED, WIFSTOPPED): Likewise.
+
 2008-10-20  Bruno Haible  <bruno@clisp.org>
 
        * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Test against another bug
index 7db28e8268a994094d2231a61515f865274cf9a6..7c045800f93ccf471b349f4ac33d64ce34cc23b7 100644 (file)
@@ -17,6 +17,7 @@ posix_spawnattr_destroy
 sigprocmask
 stdbool
 unistd
+sys_wait
 
 configure.ac:
 
index 9d3bb22d34ade1abee3f48845e0198197993b91c..0c30b88d2b4d9f1ca6b2612a4a3a6236f3b7d9c9 100644 (file)
@@ -43,25 +43,6 @@ extern char **environ;
 # define STDERR_FILENO 2
 #endif
 
-#ifndef WTERMSIG
-# define WTERMSIG(x) ((x) & 0x7f)
-#endif
-#ifndef WCOREDUMP
-# define WCOREDUMP(x) ((x) & 0x80)
-#endif
-#ifndef WEXITSTATUS
-# define WEXITSTATUS(x) (((x) >> 8) & 0xff)
-#endif
-#ifndef WIFSIGNALED
-# define WIFSIGNALED(x) (WTERMSIG (x) != 0 && WTERMSIG(x) != 0x7f)
-#endif
-#ifndef WIFEXITED
-# define WIFEXITED(x) (WTERMSIG (x) == 0)
-#endif
-#ifndef WIFSTOPPED
-# define WIFSTOPPED(x) (WTERMSIG (x) == 0x7f)
-#endif
-
 #define CHILD_PROGRAM_FILENAME "test-posix_spawn1.sh"
 
 static int
index e675822449e1d87b2b1c0800d7c03aa795674c39..826d38b969c6495897fb89cf30ed121e388246ed 100644 (file)
@@ -43,25 +43,6 @@ extern char **environ;
 # define STDERR_FILENO 2
 #endif
 
-#ifndef WTERMSIG
-# define WTERMSIG(x) ((x) & 0x7f)
-#endif
-#ifndef WCOREDUMP
-# define WCOREDUMP(x) ((x) & 0x80)
-#endif
-#ifndef WEXITSTATUS
-# define WEXITSTATUS(x) (((x) >> 8) & 0xff)
-#endif
-#ifndef WIFSIGNALED
-# define WIFSIGNALED(x) (WTERMSIG (x) != 0 && WTERMSIG(x) != 0x7f)
-#endif
-#ifndef WIFEXITED
-# define WIFEXITED(x) (WTERMSIG (x) == 0)
-#endif
-#ifndef WIFSTOPPED
-# define WIFSTOPPED(x) (WTERMSIG (x) == 0x7f)
-#endif
-
 #define CHILD_PROGRAM_FILENAME "test-posix_spawn2.sh"
 
 static int