guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] 07/27: More specific status:exit-val et al compilation g


From: Andy Wingo
Subject: [Guile-commits] 07/27: More specific status:exit-val et al compilation guards
Date: Mon, 25 Jul 2016 09:53:45 +0000 (UTC)

wingo pushed a commit to branch master
in repository guile.

commit f632d45c69d00156a63c162371e8a5ef36e1cabf
Author: Andy Wingo <address@hidden>
Date:   Mon Jul 11 22:52:35 2016 +0200

    More specific status:exit-val et al compilation guards
    
    * libguile/posix.c (scm_status_exit_val, scm_status_term_sig)
      (scm_status_stop_sig): Guard on WIFEXITED et al macros instead of on
      MinGW.
---
 libguile/posix.c |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/libguile/posix.c b/libguile/posix.c
index 66b2bed..8aa0f3e 100644
--- a/libguile/posix.c
+++ b/libguile/posix.c
@@ -718,7 +718,7 @@ SCM_DEFINE (scm_waitpid, "waitpid", 1, 1, 0,
 #undef FUNC_NAME
 #endif /* HAVE_WAITPID */
 
-#ifndef __MINGW32__
+#ifdef WIFEXITED
 SCM_DEFINE (scm_status_exit_val, "status:exit-val", 1, 0, 0, 
             (SCM status),
            "Return the exit status value, as would be set if a process\n"
@@ -737,7 +737,9 @@ SCM_DEFINE (scm_status_exit_val, "status:exit-val", 1, 0, 0,
     return SCM_BOOL_F;
 }
 #undef FUNC_NAME
+#endif /* WIFEXITED */
 
+#ifdef WIFSIGNALED
 SCM_DEFINE (scm_status_term_sig, "status:term-sig", 1, 0, 0, 
             (SCM status),
            "Return the signal number which terminated the process, if any,\n"
@@ -753,7 +755,9 @@ SCM_DEFINE (scm_status_term_sig, "status:term-sig", 1, 0, 0,
     return SCM_BOOL_F;
 }
 #undef FUNC_NAME
+#endif /* WIFSIGNALED */
 
+#ifdef WIFSTOPPED
 SCM_DEFINE (scm_status_stop_sig, "status:stop-sig", 1, 0, 0, 
             (SCM status),
            "Return the signal number which stopped the process, if any,\n"
@@ -769,7 +773,7 @@ SCM_DEFINE (scm_status_stop_sig, "status:stop-sig", 1, 0, 0,
     return SCM_BOOL_F;
 }
 #undef FUNC_NAME
-#endif /* __MINGW32__ */
+#endif /* WIFSTOPPED */
 
 #ifdef HAVE_GETPPID
 SCM_DEFINE (scm_getppid, "getppid", 0, 0, 0,



reply via email to

[Prev in Thread] Current Thread [Next in Thread]