This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: Fix thinko in dwarf2_get_pc_bounds


This fixes a problem pointed out by Martin Hunt on gdb@; I forgot to offset
the addresses by the appropriate base offset.  Oops.

I've committed this as an obvious followup to the previous patch.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer

2003-02-14  Daniel Jacobowitz  <drow@mvista.com>

	* dwarf2read.c (dwarf2_get_pc_bounds): Offset addresses by base.

Index: dwarf2read.c
===================================================================
RCS file: /cvs/src/src/gdb/dwarf2read.c,v
retrieving revision 1.85
diff -u -p -r1.85 dwarf2read.c
--- dwarf2read.c	4 Feb 2003 20:17:02 -0000	1.85
+++ dwarf2read.c	14 Feb 2003 15:10:24 -0000
@@ -2195,6 +2195,9 @@ dwarf2_get_pc_bounds (struct die_info *d
 		  return 0;
 		}
 
+	      range_beginning += base;
+	      range_end += base;
+
 	      /* FIXME: This is recording everything as a low-high
 		 segment of consecutive addresses.  We should have a
 		 data structure for discontiguous block ranges


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]