This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 039/238] [index] findcmd.c: -Wshadow fix
- From: Andrey Smirnov <andrew dot smirnov at gmail dot com>
- To: gdb-patches at sourceware dot org
- Cc: Andrey Smirnov <andrew dot smirnov at gmail dot com>
- Date: Mon, 12 Dec 2011 19:38:42 -0800
- Subject: [PATCH 039/238] [index] findcmd.c: -Wshadow fix
- References: <1323747545-29987-1-git-send-email-andrew.smirnov@gmail.com>
To ChangeLog:
* findcmd.c (put_bits): Rename `index' to `idx'(-Wshadow).
---
gdb/findcmd.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gdb/findcmd.c b/gdb/findcmd.c
index 7665a04..5eb5b75 100644
--- a/gdb/findcmd.c
+++ b/gdb/findcmd.c
@@ -38,9 +38,9 @@ put_bits (bfd_uint64_t data, char *buf, int bits, bfd_boolean big_p)
bytes = bits / 8;
for (i = 0; i < bytes; i++)
{
- int index = big_p ? bytes - i - 1 : i;
+ int idx = big_p ? bytes - i - 1 : i;
- buf[index] = data & 0xff;
+ buf[idx] = data & 0xff;
data >>= 8;
}
}
--
1.7.5.4