* defs.h (extract_signed_integer, extract_unsigned_integer,
[deliverable/binutils-gdb.git] / gdb / dwarf2loc.c
index 027e13588794405ad6142087f1a40af0b004649a..7a54f436ab53c6a901aff143a0b825c6fb8b84d6 100644 (file)
@@ -57,6 +57,7 @@ find_location_expression (struct dwarf2_loclist_baton *baton,
   int length;
   struct objfile *objfile = dwarf2_per_cu_objfile (baton->per_cu);
   struct gdbarch *gdbarch = get_objfile_arch (objfile);
+  enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
   unsigned int addr_size = dwarf2_per_cu_addr_size (baton->per_cu);
   CORE_ADDR base_mask = ~(~(CORE_ADDR)1 << (addr_size * 8 - 1));
   /* Adjust base_address for relocatable objects.  */
@@ -89,7 +90,7 @@ find_location_expression (struct dwarf2_loclist_baton *baton,
       low += base_address;
       high += base_address;
 
-      length = extract_unsigned_integer (loc_ptr, 2);
+      length = extract_unsigned_integer (loc_ptr, 2, byte_order);
       loc_ptr += 2;
 
       if (pc >= low && pc < high)
This page took 0.024828 seconds and 4 git commands to generate.