This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 20/348] Fix -Wsahdow warnings


>From 34aaf4f75c58e9a453184a8df62d7b871afd2e54 Mon Sep 17 00:00:00 2001
From: Andrey Smirnov <andrew.smirnov@gmail.com>
Date: Tue, 22 Nov 2011 17:29:45 +0700
Subject: [PATCH 20/39] Fix -Wshadow warnings.

* amd64-tdep.c (amd64_push_dummy_call): Fix -Wshadow
warnings.
---
 gdb/ChangeLog    |    5 +++++
 gdb/amd64-tdep.c |    5 +++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 645743b..4daf760 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,10 @@
 2011-11-22  Andrey Smirnov <andrew.smirnov@gmail.com>
 
+	* amd64-tdep.c (amd64_push_dummy_call): Fix -Wshadow
+	warnings.
+
+2011-11-22  Andrey Smirnov <andrew.smirnov@gmail.com>
+
 	* amd64-tdep.c (amd64_get_unused_input_int_reg): Fix -Wshadow
 	warnings.
 
diff --git a/gdb/amd64-tdep.c b/gdb/amd64-tdep.c
index 29101a4..095a34f 100644
--- a/gdb/amd64-tdep.c
+++ b/gdb/amd64-tdep.c
@@ -878,10 +878,11 @@ amd64_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
   /* Pass "hidden" argument".  */
   if (struct_return)
     {
-      struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
       /* The "hidden" argument is passed throught the first argument
          register.  */
-      const int arg_regnum = tdep->call_dummy_integer_regs[0];
+
+      const int arg_regnum =
+        gdbarch_tdep (gdbarch)->call_dummy_integer_regs[0];
 
       store_unsigned_integer (buf, 8, byte_order, struct_addr);
       regcache_cooked_write (regcache, arg_regnum, buf);
-- 
1.7.5.4


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]