This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[PATCH] Fix x86_64_fill_fxsave()
- From: Michal Ludvig <mludvig at suse dot cz>
- To: gdb-patches at sources dot redhat dot com
- Date: Fri, 06 Jun 2003 12:07:01 +0200
- Subject: [PATCH] Fix x86_64_fill_fxsave()
Hi,
attached is a patch for x86_64_fill_fxsave(). Originally it sometimes
passed regno == -1 to regcache_collect which triggered GDB internal
error. Now it passes correct values.
Committed as obvious.
Michal Ludvig
2003-06-06 Michal Ludvig <mludvig@suse.cz>
* x86-64-tdep.c (x86_64_fill_fxsave): Pass correct regnums
to regcache_collect().
Index: x86-64-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/x86-64-tdep.c,v
retrieving revision 1.76
diff -u -p -r1.76 x86-64-tdep.c
--- x86-64-tdep.c 5 Jun 2003 18:54:34 -0000 1.76
+++ x86-64-tdep.c 6 Jun 2003 10:02:42 -0000
@@ -1246,7 +1246,7 @@ x86_64_fill_fxsave (char *fxsave, int re
i387_fill_fxsave (fxsave, regnum);
if (regnum == -1 || regnum == I387_FISEG_REGNUM)
- regcache_collect (regnum, fxsave + 12);
+ regcache_collect (I387_FISEG_REGNUM, fxsave + 12);
if (regnum == -1 || regnum == I387_FOSEG_REGNUM)
- regcache_collect (regnum, fxsave + 20);
+ regcache_collect (I387_FOSEG_REGNUM, fxsave + 20);
}