This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[RFA] Small memattr fix
- From: Don Howard <dhoward at redhat dot com>
- To: <gdb-patches at sources dot redhat dot com>
- Date: Thu, 30 May 2002 18:04:14 -0700 (PDT)
- Subject: [RFA] Small memattr fix
The following patch fixes gdb's bogus complaint that
mem 0x0 0x04 ...
overlaps with
mem 0x4 0x08 ...
2002-05-30 Don Howard <dhoward@redhat.com>
* memattr.c (create_mem_region): Don't include upper address in
test for overlapping mem regions.
Index: memattr.c
===================================================================
RCS file: /cvs/cvsfiles/devo/gdb/memattr.c,v
retrieving revision 2.5.22.1
diff -p -u -w -r2.5.22.1 memattr.c
--- memattr.c 2002/02/05 00:31:36 2.5.22.1
+++ memattr.c 2002/05/31 00:55:20
@@ -55,8 +55,8 @@ create_mem_region (CORE_ADDR lo, CORE_AD
while (n)
{
/* overlapping node */
- if ((lo >= n->lo && lo <= n->hi) ||
- (hi >= n->lo && hi <= n->hi))
+ if ((lo >= n->lo && lo < n->hi) ||
+ (hi > n->lo && hi <= n->hi))
{
printf_unfiltered ("overlapping memory region\n");
return NULL;
--
dhoward@redhat.com
gdb engineering