]> Savannah Git Hosting - gnulib.git/commitdiff
execute, spawn-pipe: Avoid warning about redefining 'close'.
authorBruno Haible <bruno@clisp.org>
Sat, 12 May 2018 11:32:52 +0000 (13:32 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 12 May 2018 11:32:52 +0000 (13:32 +0200)
Reported by Eli Zaretskii <eliz@gnu.org>.

* lib/execute.c: Undefine 'close' before redefining it.
* lib/spawn-pipe.c: Likewise.

ChangeLog
lib/execute.c
lib/spawn-pipe.c

index 95a4203631c2d67f86b376e6d7edee87d63fc65f..1e77eb085966115ad038137d8a503fbce7e61e7c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2018-05-12  Bruno Haible  <bruno@clisp.org>
+
+       execute, spawn-pipe: Avoid warning about redefining 'close'.
+       Reported by Eli Zaretskii <eliz@gnu.org>.
+       * lib/execute.c: Undefine 'close' before redefining it.
+       * lib/spawn-pipe.c: Likewise.
+
 2018-05-12  Bruno Haible  <bruno@clisp.org>
 
        nanosleep: Avoid test failure on mingw when it has nanosleep.
index 45326610d0753793c2d2f2a3937f123f96c4b11b..1194dd61302615397e8bc5a45435cd8940e0815a 100644 (file)
@@ -66,6 +66,7 @@ nonintr_close (int fd)
 
   return retval;
 }
+#undef close /* avoid warning related to gnulib module unistd */
 #define close nonintr_close
 
 static int
index 716c54a6c7ca3df0f56a878dabf589c8254ad6b9..ec9bd9dc0ae0f771f9b10ddec20a5bd5ebc138bf 100644 (file)
@@ -71,6 +71,7 @@ nonintr_close (int fd)
 
   return retval;
 }
+#undef close /* avoid warning related to gnulib module unistd */
 #define close nonintr_close
 
 #if defined _WIN32 && ! defined __CYGWIN__