aboutsummaryrefslogtreecommitdiff
path: root/gdb/nat/x86-dregs.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@adacore.com>2021-09-03 10:29:58 -0600
committerTom Tromey <tromey@adacore.com>2021-09-03 11:30:46 -0600
commit7a2813c00be99356b30e568d87a4adaf651de1d8 (patch)
treeb0d290808f54c8a7f42cda59a425b61a89421aee /gdb/nat/x86-dregs.c
parenta640adf7cfb7920d7a0b6b34a671ea138a9cdc83 (diff)
downloadgdb-7a2813c00be99356b30e568d87a4adaf651de1d8.zip
gdb-7a2813c00be99356b30e568d87a4adaf651de1d8.tar.gz
gdb-7a2813c00be99356b30e568d87a4adaf651de1d8.tar.bz2
Use CORE_ADDR as return type from x86_dr_low_get_addr
On a Windows build locally, watchpoints started failing. I tracked this down to x86_dr_low_get_addr returning an 'unsigned long'... in this particular build, this is a 32-bit type, but the inferior is a 64-bit program. This patch fixes the problem by changing the return type. No other change is required, because this matches the function pointer in struct x86_dr_low_type.
Diffstat (limited to 'gdb/nat/x86-dregs.c')
-rw-r--r--gdb/nat/x86-dregs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/nat/x86-dregs.c b/gdb/nat/x86-dregs.c
index cf8e517..2475164 100644
--- a/gdb/nat/x86-dregs.c
+++ b/gdb/nat/x86-dregs.c
@@ -52,7 +52,7 @@ x86_dr_low_set_addr (struct x86_debug_reg_state *new_state, int i)
/* Return the inferior's debug register REGNUM. */
-static unsigned long
+static CORE_ADDR
x86_dr_low_get_addr (int i)
{
return x86_dr_low.get_addr (i);