aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1996-11-12 18:26:10 -0500
committerRichard Kenner <kenner@gcc.gnu.org>1996-11-12 18:26:10 -0500
commitca8a7793bf14b4578df375988254cd2eb911ded0 (patch)
treec318a89a73f21caa13572897c8ee1014bc82a498
parent5a570aded7e26742020c1ef3942c85619d886bc0 (diff)
downloadgcc-ca8a7793bf14b4578df375988254cd2eb911ded0.zip
gcc-ca8a7793bf14b4578df375988254cd2eb911ded0.tar.gz
gcc-ca8a7793bf14b4578df375988254cd2eb911ded0.tar.bz2
(vfork): Supply new definition for VMS.
(pwait): Use waitpid instead of wait for VMS. From-SVN: r13151
-rw-r--r--gcc/pexecute.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc/pexecute.c b/gcc/pexecute.c
index 1814b71..457a6d3 100644
--- a/gcc/pexecute.c
+++ b/gcc/pexecute.c
@@ -444,9 +444,14 @@ pfinish ()
#if ! defined (__MSDOS__) && ! defined (OS2) && ! defined (MPW) \
&& (defined (__CYGWIN32__) || ! defined (_WIN32))
+#ifdef VMS
+#define vfork() (decc$$alloc_vfork_blocks() >= 0 ? \
+ lib$get_current_invo_context(decc$$get_vfork_jmpbuf()) : -1)
+#else
#ifdef USG
#define vfork fork
#endif
+#endif
extern int execv ();
extern int execvp ();
@@ -575,7 +580,11 @@ pwait (pid, status, flags)
{
/* ??? Here's an opportunity to canonicalize the values in STATUS.
Needed? */
+#ifdef VMS
+ pid = waitpid (-1, status, 0);
+#else
pid = wait (status);
+#endif
return pid;
}