From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7715 invoked by alias); 19 Nov 2006 00:05:25 -0000 Received: (qmail 7706 invoked by uid 22791); 19 Nov 2006 00:05:24 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Sun, 19 Nov 2006 00:05:19 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1GlaBQ-0007Yn-Qu; Sat, 18 Nov 2006 19:05:16 -0500 Date: Sun, 19 Nov 2006 00:05:00 -0000 From: Daniel Jacobowitz To: Vladimir Prus Cc: gdb-patches@sources.redhat.com Subject: Re: Check memory accesses Message-ID: <20061119000516.GD28256@nevyn.them.org> Mail-Followup-To: Vladimir Prus , gdb-patches@sources.redhat.com References: <200611092336.22512.vladimir@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.13 (2006-08-11) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-11/txt/msg00206.txt.bz2 On Wed, Nov 15, 2006 at 03:24:07PM +0300, Vladimir Prus wrote: > + /* region->hi means there's no upper bound. */ > + if (memaddr + len < region->hi || region->hi == 0) "region->hi == 0", you mean (in the comment)? Also, two spaces after period. > +++ gdb/memattr.c (/patches/gdb/memcheck/gdb_mainline) (revision 2094) > @@ -29,6 +29,7 @@ > #include "language.h" > #include "vec.h" > #include "gdb_string.h" > +#include "gdb_locale.h" Shouldn't need this? It's part of defs.h (deliberately, since everywhere should use _()). > if (m->enabled_p == 1) > { > + /* If address is in memory return, return that memory range. */ I think you mean "if the adderss is in the memory region". > + /* When no memory map is defined at all, we always set 'default_mem_attrib', > + so that we do not make the all memory inaccessible for targets that don't > + provide a memory map. */ Always return, rather than "always set"? Also, "make all memory". -- Daniel Jacobowitz CodeSourcery