aboutsummaryrefslogtreecommitdiff
path: root/gdb/nat
diff options
context:
space:
mode:
authorJon Turney <jon.turney@dronecode.org.uk>2022-06-12 16:39:46 +0100
committerJon Turney <jon.turney@dronecode.org.uk>2022-11-02 14:36:14 +0000
commit559a5ea452455d95ff18736ce6dfa9065427f74e (patch)
tree74c716d89647beca8c51bd0df51a3ee710bb6b04 /gdb/nat
parent39a28a7cf2b3854a9592e1d3d9f675394d4aef6d (diff)
downloadgdb-559a5ea452455d95ff18736ce6dfa9065427f74e.zip
gdb-559a5ea452455d95ff18736ce6dfa9065427f74e.tar.gz
gdb-559a5ea452455d95ff18736ce6dfa9065427f74e.tar.bz2
Fix Cygwin build after bcb9251f
Absent _UNICODE being defined (which gdb's Makefile doesn't do), windows.h will always define STARTUPINFO is as STARTUPINFOA, so this cast isn't correct when create_process expects a STARTUPINFOW parameter (i.e. in a Cygwin build). Instead write this as &info_ex.StartupInfo (which is always of the correct type).
Diffstat (limited to 'gdb/nat')
-rw-r--r--gdb/nat/windows-nat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/nat/windows-nat.c b/gdb/nat/windows-nat.c
index ba60b58..42031d4 100644
--- a/gdb/nat/windows-nat.c
+++ b/gdb/nat/windows-nat.c
@@ -831,7 +831,7 @@ create_process_wrapper (FUNC *do_create_process, const CHAR *image,
| EXTENDED_STARTUPINFO_PRESENT),
environment,
cur_dir,
- (STARTUPINFO *) &info_ex,
+ &info_ex.StartupInfo,
process_info);
if (result)
return_value = result;