This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 042/238] [index] exec.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:45 -0800
- Subject: [PATCH 042/238] [index] exec.c: -Wshadow fix
- References: <1323747545-29987-1-git-send-email-andrew.smirnov@gmail.com>
To ChangeLog:
* exec.c (exec_set_section_address): Rename `index' to
`idx'(-Wshadow).
---
gdb/exec.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gdb/exec.c b/gdb/exec.c
index a2da9d5..d3d3493 100644
--- a/gdb/exec.c
+++ b/gdb/exec.c
@@ -838,7 +838,7 @@ set_section_command (char *args, int from_tty)
it to ADDRESS. */
void
-exec_set_section_address (const char *filename, int index, CORE_ADDR address)
+exec_set_section_address (const char *filename, int idx, CORE_ADDR address)
{
struct target_section *p;
struct target_section_table *table;
@@ -847,7 +847,7 @@ exec_set_section_address (const char *filename, int index, CORE_ADDR address)
for (p = table->sections; p < table->sections_end; p++)
{
if (filename_cmp (filename, p->bfd->filename) == 0
- && index == p->the_bfd_section->index)
+ && idx == p->the_bfd_section->index)
{
p->endaddr += address - p->addr;
p->addr = address;
--
1.7.5.4