aboutsummaryrefslogtreecommitdiff
path: root/gdb/values.c
diff options
context:
space:
mode:
authorDaniel Jacobowitz <drow@false.org>2001-11-30 17:47:51 +0000
committerDaniel Jacobowitz <drow@false.org>2001-11-30 17:47:51 +0000
commit21cfb3b661790e5e3153db2158f16c3991074553 (patch)
treee44271a3895e7bdced5d391621a51cf303155392 /gdb/values.c
parent215007a64883740af82c24537ecf5641163159f2 (diff)
downloadgdb-21cfb3b661790e5e3153db2158f16c3991074553.zip
gdb-21cfb3b661790e5e3153db2158f16c3991074553.tar.gz
gdb-21cfb3b661790e5e3153db2158f16c3991074553.tar.bz2
* values.c (value_primitive_field): Add embedded_offset to the
address of structure members. * gnu-v3-abi.c (gnuv3_rtti_type): Cast to base type before attempting to access vtable pointer. Set using_enc_p if we cast. (gnuv3_virtual_fn_field): Call value_cast with structure rather than structure pointer. Cast to base type before attempting to access vtable pointer.
Diffstat (limited to 'gdb/values.c')
-rw-r--r--gdb/values.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/values.c b/gdb/values.c
index d9a523f..5647097 100644
--- a/gdb/values.c
+++ b/gdb/values.c
@@ -929,7 +929,8 @@ value_primitive_field (register value_ptr arg1, int offset,
memcpy (VALUE_CONTENTS_RAW (v),
VALUE_CONTENTS_RAW (arg1) + offset,
TYPE_LENGTH (type));
- VALUE_OFFSET (v) = VALUE_OFFSET (arg1) + offset;
+ VALUE_OFFSET (v) = VALUE_OFFSET (arg1) + offset
+ + VALUE_EMBEDDED_OFFSET (arg1);
}
VALUE_LVAL (v) = VALUE_LVAL (arg1);
if (VALUE_LVAL (arg1) == lval_internalvar)