aboutsummaryrefslogtreecommitdiff
path: root/gdb/valops.c
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2010-05-07 18:49:27 +0000
committerMichael Snyder <msnyder@vmware.com>2010-05-07 18:49:27 +0000
commitd160942fa5f8a18a1b237c028254382bcb836924 (patch)
treeca413746c29d519228a03111159e5cf9e4e92ba4 /gdb/valops.c
parent92750f34a6c6194646b606b2dc0f6b987dd35187 (diff)
downloadfsf-binutils-gdb-d160942fa5f8a18a1b237c028254382bcb836924.zip
fsf-binutils-gdb-d160942fa5f8a18a1b237c028254382bcb836924.tar.gz
fsf-binutils-gdb-d160942fa5f8a18a1b237c028254382bcb836924.tar.bz2
2010-05-07 Michael Snyder <msnyder@vmware.com>
* valops.c (value_cast_pointers): Restore unused variable 'type1', and use it to compute variable 't1'.
Diffstat (limited to 'gdb/valops.c')
-rw-r--r--gdb/valops.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/valops.c b/gdb/valops.c
index 7979db9..e18d9c8 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -300,8 +300,9 @@ value_cast_structs (struct type *type, struct value *v2)
struct value *
value_cast_pointers (struct type *type, struct value *arg2)
{
+ struct type *type1 = check_typedef (type);
struct type *type2 = check_typedef (value_type (arg2));
- struct type *t1 = check_typedef (TYPE_TARGET_TYPE (type));
+ struct type *t1 = check_typedef (TYPE_TARGET_TYPE (type1));
struct type *t2 = check_typedef (TYPE_TARGET_TYPE (type2));
if (TYPE_CODE (t1) == TYPE_CODE_STRUCT