[RFA/win32] CONTEXT_EXTENDED_REGISTERS is not defined on x86_64-windows
Joel Brobecker
brobecker@adacore.com
Wed Jan 7 11:35:00 GMT 2009
Hello,
win32-nat.c uses CONTEXT_EXTENDED_REGISTERS in the following macro
declaration:
#define CONTEXT_DEBUGGER_DR CONTEXT_DEBUGGER | CONTEXT_DEBUG_REGISTERS \
| CONTEXT_EXTENDED_REGISTERS
However, CONTEXT_EXTENDED_REGISTERS is not defined on x86_64-windows.
It seems to me that this macro only makes sense on i386, so I simply
defined it to 0 if not already defined. This should have no effect
on x86-windows while doing the right thing on x86_64-windows.
2009-01-07 Joel Brobecker <brobecker@adacore.com>
* win32-nat.c (CONTEXT_EXTENDED_REGISTERS): Define to 0 if not
already defined.
Tested on x86-windows.
OK to apply?
Thanks,
--
Joel
-------------- next part --------------
diff --git a/gdb/win32-nat.c b/gdb/win32-nat.c
index 51443a3..1b15dfb 100644
--- a/gdb/win32-nat.c
+++ b/gdb/win32-nat.c
@@ -85,6 +85,12 @@ enum
#endif
#include <psapi.h>
+#ifndef CONTEXT_EXTENDED_REGISTERS
+/* This macro is only defined on ia32. It only makes sense on this target,
+ so define it as zero if not already defined. */
+#define CONTEXT_EXTENDED_REGISTERS 0
+#endif
+
#define CONTEXT_DEBUGGER_DR CONTEXT_DEBUGGER | CONTEXT_DEBUG_REGISTERS \
| CONTEXT_EXTENDED_REGISTERS
More information about the Gdb-patches
mailing list