s/struct _serial_t/struct serial/
[deliverable/binutils-gdb.git] / gdb / values.c
index bb441cd5ead27957ae249355a2b2dfcba12ae261..0d18c31cf44fc55d1bfbff9f93980edc7674a97c 100644 (file)
@@ -595,9 +595,10 @@ value_as_pointer (value_ptr val)
      can be different and may require different integer to pointer
      conversions. */
   if (TYPE_CODE (VALUE_TYPE (val)) == TYPE_CODE_INT
-      && TYPE_LENGTH (VALUE_TYPE (val)) <= TYPE_LENGTH (builtin_type_ptr))
+      && (TYPE_LENGTH (VALUE_TYPE (val))
+         <= TYPE_LENGTH (builtin_type_void_data_ptr)))
     {
-      val = value_cast (builtin_type_ptr, val);
+      val = value_cast (builtin_type_void_data_ptr, val);
     }
   return unpack_long (VALUE_TYPE (val), VALUE_CONTENTS (val));
 #endif
@@ -1328,7 +1329,7 @@ value_being_returned (struct type *valtype, char *retbuf, int struct_return)
   CORE_ADDR addr;
 
   /* If this is not defined, just use EXTRACT_RETURN_VALUE instead.  */
-  if (EXTRACT_STRUCT_VALUE_ADDRESS_P)
+  if (EXTRACT_STRUCT_VALUE_ADDRESS_P ())
     if (struct_return)
       {
        addr = EXTRACT_STRUCT_VALUE_ADDRESS (retbuf);
This page took 0.023908 seconds and 4 git commands to generate.