aboutsummaryrefslogtreecommitdiff
path: root/gdb/value.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/value.c')
-rw-r--r--gdb/value.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/gdb/value.c b/gdb/value.c
index d96c07b..7370257 100644
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -3188,10 +3188,7 @@ value_from_contents_and_address (struct type *type,
if (valaddr == NULL)
v = allocate_value_lazy (type);
else
- {
- v = allocate_value (type);
- memcpy (value_contents_raw (v), valaddr, TYPE_LENGTH (type));
- }
+ v = value_from_contents (type, valaddr);
set_value_address (v, address);
VALUE_LVAL (v) = lval_memory;
return v;