Fix Cygwin compilation after target_ops C++ conversion.
authorJon Turney <jon.turney@dronecode.org.uk>
Sat, 14 Jul 2018 11:17:29 +0000 (12:17 +0100)
committerJon Turney <jon.turney@dronecode.org.uk>
Thu, 26 Jul 2018 21:26:27 +0000 (22:26 +0100)
After f6ac5f3d "Convert struct target_ops to C++", we need to explicitly use
the global namespace when calling ::close() from windows_nat_target methods,
as that object has a close() method.

gdb/ChangeLog:

2018-07-14  Jon Turney  <jon.turney@dronecode.org.uk>

* windows-nat.c (windows_nat_target::create_inferior): Update to
call close() in global namespace.

gdb/ChangeLog
gdb/windows-nat.c

index 6e80efd4f0d239f54922b8b04b4dbd63b7f6cb6b..8a63224acec95d5b65f64b7b797198413965dde3 100644 (file)
@@ -1,3 +1,8 @@
+2018-07-14  Jon Turney  <jon.turney@dronecode.org.uk>
+
+       * windows-nat.c (windows_nat_target::create_inferior): Update to
+       call close() in global namespace.
+
 2018-07-26  Tom Tromey  <tom@tromey.com>
 
        * dwarf-index-write.c (add_address_entry): Don't add objfile
index e0e422c0f052b5e797d05a4f019cf35debab83c3..aea502638e021cfe125ae5fdb7a5c3b98a3fc3fd 100644 (file)
@@ -2681,13 +2681,13 @@ windows_nat_target::create_inferior (const char *exec_file,
 
   if (tty >= 0)
     {
-      close (tty);
+      ::close (tty);
       dup2 (ostdin, 0);
       dup2 (ostdout, 1);
       dup2 (ostderr, 2);
-      close (ostdin);
-      close (ostdout);
-      close (ostderr);
+      ::close (ostdin);
+      ::close (ostdout);
+      ::close (ostderr);
     }
 #else  /* !__CYGWIN__ */
   allargs_len = strlen (allargs);
This page took 0.031909 seconds and 4 git commands to generate.