diff options
author | Michael Snyder <msnyder@vmware.com> | 2011-02-26 23:45:01 +0000 |
---|---|---|
committer | Michael Snyder <msnyder@vmware.com> | 2011-02-26 23:45:01 +0000 |
commit | e5b3d7d6f3e1894c12b6c44f5c0cff472726eb31 (patch) | |
tree | 7f109d03a767659c3909c6c6f5f23179c040f0e0 | |
parent | 5eee517dae62b3a4ef81aa9536272ff5a7e98d2f (diff) | |
download | gdb-e5b3d7d6f3e1894c12b6c44f5c0cff472726eb31.zip gdb-e5b3d7d6f3e1894c12b6c44f5c0cff472726eb31.tar.gz gdb-e5b3d7d6f3e1894c12b6c44f5c0cff472726eb31.tar.bz2 |
2011-02-26 Michael Snyder <msnyder@vmware.com>
* i387-tdep.c (i387_supply_xsave): Avoid shadowing a function
param with a local variable of the same name.
-rw-r--r-- | gdb/ChangeLog | 3 | ||||
-rw-r--r-- | gdb/i387-tdep.c | 4 |
2 files changed, 5 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 828994e..e33ade5 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,8 @@ 2011-02-26 Michael Snyder <msnyder@vmware.com> + * i387-tdep.c (i387_supply_xsave): Avoid shadowing a function + param with a local variable of the same name. + * linux-low.c (linux_nat_xfer_osdata): Rename local variable so that it does not shadow a function parameter. diff --git a/gdb/i387-tdep.c b/gdb/i387-tdep.c index 7ec7f53..8267466 100644 --- a/gdb/i387-tdep.c +++ b/gdb/i387-tdep.c @@ -882,9 +882,9 @@ i387_supply_xsave (struct regcache *regcache, int regnum, if (val[0] & (1 << fpreg)) { - int regnum = (fpreg + 8 - top) % 8 + int thisreg = (fpreg + 8 - top) % 8 + I387_ST0_REGNUM (tdep); - tag = i387_tag (FXSAVE_ADDR (tdep, regs, regnum)); + tag = i387_tag (FXSAVE_ADDR (tdep, regs, thisreg)); } else tag = 3; /* Empty */ |