* [PATCH] i386-linux-nat.c: Use regcache_collect() in fill_gregset()
@ 2001-11-07 9:59 Kevin Buettner
2001-11-07 14:37 ` Kevin Buettner
0 siblings, 1 reply; 2+ messages in thread
From: Kevin Buettner @ 2001-11-07 9:59 UTC (permalink / raw)
To: gdb-patches
I've just committed the following change...
* i386-linux-nat.c (fill_gregset): Use regcache_collect() instead
of accessing registers[] directly.
Index: i386-linux-nat.c
===================================================================
RCS file: /cvs/src/src/gdb/i386-linux-nat.c,v
retrieving revision 1.30
diff -u -p -r1.30 i386-linux-nat.c
--- i386-linux-nat.c 2001/11/17 23:53:16 1.30
+++ i386-linux-nat.c 2001/11/18 01:15:56
@@ -322,11 +322,10 @@ fill_gregset (elf_gregset_t *gregsetp, i
for (i = 0; i < NUM_GREGS; i++)
if ((regno == -1 || regno == i))
- *(regp + regmap[i]) = *(elf_greg_t *) ®isters[REGISTER_BYTE (i)];
+ regcache_collect (i, regp + regmap[i]);
if (regno == -1 || regno == I386_LINUX_ORIG_EAX_REGNUM)
- *(regp + regmap[ORIG_EAX]) =
- *(elf_greg_t *) ®isters[REGISTER_BYTE (I386_LINUX_ORIG_EAX_REGNUM)];
+ regcache_collect (I386_LINUX_ORIG_EAX_REGNUM, regp + regmap[ORIG_EAX]);
}
#ifdef HAVE_PTRACE_GETREGS
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: [PATCH] i386-linux-nat.c: Use regcache_collect() in fill_gregset()
2001-11-07 9:59 [PATCH] i386-linux-nat.c: Use regcache_collect() in fill_gregset() Kevin Buettner
@ 2001-11-07 14:37 ` Kevin Buettner
0 siblings, 0 replies; 2+ messages in thread
From: Kevin Buettner @ 2001-11-07 14:37 UTC (permalink / raw)
To: gdb-patches
On Nov 17, 6:21pm, Kevin Buettner wrote:
> I've just committed the following change...
>
> * i386-linux-nat.c (fill_gregset): Use regcache_collect() instead
> of accessing registers[] directly.
But I screwed it up. I've just committed the following patch which fixes
it...
* i386-linux-nat.c (fill_gregset): Fix botched regcache_collect()
conversion for I386_LINUX_ORIG_EAX_REGNUM.
Index: i386-linux-nat.c
===================================================================
RCS file: /cvs/src/src/gdb/i386-linux-nat.c,v
retrieving revision 1.31
diff -u -p -r1.31 i386-linux-nat.c
--- i386-linux-nat.c 2001/11/18 01:19:47 1.31
+++ i386-linux-nat.c 2001/11/18 21:35:37
@@ -325,7 +325,7 @@ fill_gregset (elf_gregset_t *gregsetp, i
regcache_collect (i, regp + regmap[i]);
if (regno == -1 || regno == I386_LINUX_ORIG_EAX_REGNUM)
- regcache_collect (I386_LINUX_ORIG_EAX_REGNUM, regp + regmap[ORIG_EAX]);
+ regcache_collect (I386_LINUX_ORIG_EAX_REGNUM, regp + ORIG_EAX);
}
#ifdef HAVE_PTRACE_GETREGS
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-11-18 21:40 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-11-07 9:59 [PATCH] i386-linux-nat.c: Use regcache_collect() in fill_gregset() Kevin Buettner
2001-11-07 14:37 ` Kevin Buettner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox