aboutsummaryrefslogtreecommitdiff
path: root/gdb/amd64-windows-tdep.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/amd64-windows-tdep.c')
-rw-r--r--gdb/amd64-windows-tdep.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/gdb/amd64-windows-tdep.c b/gdb/amd64-windows-tdep.c
index 88ff794..e0346f8 100644
--- a/gdb/amd64-windows-tdep.c
+++ b/gdb/amd64-windows-tdep.c
@@ -1249,10 +1249,13 @@ amd64_windows_osabi_sniffer (bfd *abfd)
{
const char *target_name = bfd_get_target (abfd);
- if (strcmp (target_name, "pei-x86-64") == 0)
- return GDB_OSABI_WINDOWS;
+ if (!streq (target_name, "pei-x86-64"))
+ return GDB_OSABI_UNKNOWN;
- return GDB_OSABI_UNKNOWN;
+ if (is_linked_with_cygwin_dll (abfd))
+ return GDB_OSABI_CYGWIN;
+
+ return GDB_OSABI_WINDOWS;
}
void _initialize_amd64_windows_tdep ();