* defs.h (extract_signed_integer, extract_unsigned_integer,
[deliverable/binutils-gdb.git] / gdb / procfs.c
index 378042dbeed1f3eb11feb7013084bf20b00cf0f3..80479e351709c24a1ee3404f3bfcfc2142a76a09 100644 (file)
@@ -162,6 +162,7 @@ static int
 procfs_auxv_parse (struct target_ops *ops, gdb_byte **readptr,
                   gdb_byte *endptr, CORE_ADDR *typep, CORE_ADDR *valp)
 {
+  enum bfd_endian byte_order = gdbarch_byte_order (target_gdbarch);
   gdb_byte *ptr = *readptr;
 
   if (endptr == ptr)
@@ -170,11 +171,11 @@ procfs_auxv_parse (struct target_ops *ops, gdb_byte **readptr,
   if (endptr - ptr < 8 * 2)
     return -1;
 
-  *typep = extract_unsigned_integer (ptr, 4);
+  *typep = extract_unsigned_integer (ptr, 4, byte_order);
   ptr += 8;
   /* The size of data is always 64-bit.  If the application is 32-bit,
      it will be zero extended, as expected.  */
-  *valp = extract_unsigned_integer (ptr, 8);
+  *valp = extract_unsigned_integer (ptr, 8, byte_order);
   ptr += 8;
 
   *readptr = ptr;
This page took 0.025768 seconds and 4 git commands to generate.