diff options
author | Sanimir Agovic <sagovic@sourceware.org> | 2013-08-29 12:21:29 +0000 |
---|---|---|
committer | Sanimir Agovic <sagovic@sourceware.org> | 2013-08-29 12:21:29 +0000 |
commit | 314c7de970512fe51bcd24829306c4aee2ada762 (patch) | |
tree | 097cc2a6f2f52ace2ade525ad8245c67fe6a26b8 /gdb/value.c | |
parent | 5c98a14e1e4ffe0e8754ca07e50c564e1a22d6c1 (diff) | |
download | gdb-314c7de970512fe51bcd24829306c4aee2ada762.zip gdb-314c7de970512fe51bcd24829306c4aee2ada762.tar.gz gdb-314c7de970512fe51bcd24829306c4aee2ada762.tar.bz2 |
cleanup: replace allocate_value and memcpy with value_from_contents
2013-08-29 Sanimir Agovic <sanimir.agovic@intel.com>
* value.c (value_from_contents_and_address): Replace allocate_value and
memcpy with value_from_contents.
Diffstat (limited to 'gdb/value.c')
-rw-r--r-- | gdb/value.c | 5 |
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; |