guile-commits
[Top][All Lists]
Advanced

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

[Guile-commits] 04/15: Clear errno before CreateProcess for MinGW.


From: Jan Nieuwenhuizen
Subject: [Guile-commits] 04/15: Clear errno before CreateProcess for MinGW.
Date: Mon, 12 Apr 2021 05:55:42 -0400 (EDT)

janneke pushed a commit to branch wip-mingw
in repository guile.

commit 722351eb786fe79db918d2dbeaf2c592faf4e05e
Author: Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
AuthorDate: Wed Apr 1 18:03:09 2020 +0200

    Clear errno before CreateProcess for MinGW.
    
    * libguile/posix-w32.c (start_child): Avoid recursing (and breaking any
    PIPE setup) when running in WINE.
---
 libguile/posix-w32.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/libguile/posix-w32.c b/libguile/posix-w32.c
index f11c526..bfeb971 100644
--- a/libguile/posix-w32.c
+++ b/libguile/posix-w32.c
@@ -618,6 +618,10 @@ start_child (const char *exec_file, char **argv,
   intptr_t pid;
   int bin_sh_replaced = 0;
 
+  /* When running in WINE, chances are we hit ENOENT (possibly transated
+     to ENOEXEC).  */
+  errno = 0;
+
   if (!reading)
     c2p[1] = outfd;
   if (!writing)



reply via email to

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