public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] Fix target remote pipe command for MinGW
@ 2022-12-22 15:22 Jonas Hoerberg
  2023-01-02 15:10 ` Tom Tromey
  0 siblings, 1 reply; 2+ messages in thread
From: Jonas Hoerberg @ 2022-12-22 15:22 UTC (permalink / raw)
  To: gdb-patches

The cced7cacecad104fff0 ("gdb: preserve `|` in connection details string")
commit added '|' detection and removal to ser-pipe.c, but missed to add it
to ser-mingw.c.

This results in the error message below for MinGW hosts:
error starting child process '| <executable> <args>': CreateProcess: No such file or directory

This commit add the missing '|' detection and removal to ser-mingw.c.
---
 gdb/ser-mingw.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/gdb/ser-mingw.c b/gdb/ser-mingw.c
index a62502b8d54..94b4d0df5da 100644
--- a/gdb/ser-mingw.c
+++ b/gdb/ser-mingw.c
@@ -867,6 +867,12 @@ pipe_windows_open (struct serial *scb, const char *name)
   if (name == NULL)
     error_no_arg (_("child command"));

+  if (*name == '|')
+    {
+      name++;
+      name = skip_spaces (name);
+    }
+
   gdb_argv argv (name);

   if (! argv[0] || argv[0][0] == '\0')
--
2.39.0.windows.1


Classified as Business

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-01-02 15:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-22 15:22 [PATCH] Fix target remote pipe command for MinGW Jonas Hoerberg
2023-01-02 15:10 ` Tom Tromey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).