s/struct _serial_t/struct serial/
[deliverable/binutils-gdb.git] / gdb / values.c
index 43ff194c160f611491ec4267a8b868be4209c92d..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
This page took 0.024016 seconds and 4 git commands to generate.