cleanup: replace allocate_value and memcpy with value_from_contents
[deliverable/binutils-gdb.git] / gdb / value.c
index d96c07b10cdc61cd73576b66adc7986784aae33c..73702571dd153f9633e3526f5805abe8638ebc97 100644 (file)
@@ -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;
This page took 0.0257309999999999 seconds and 4 git commands to generate.