From owner-freebsd-current Wed May 29 0:19:31 2002 Delivered-To: freebsd-current@freebsd.org Received: from van-laarhoven.org (ap-z-5ab8.adsl.wanadoo.nl [212.129.218.184]) by hub.freebsd.org (Postfix) with SMTP id 8AF4E37B40A for ; Wed, 29 May 2002 00:19:21 -0700 (PDT) Received: (qmail 84982 invoked from network); 29 May 2002 07:19:19 -0000 Received: from heather.van-laarhoven.org (10.66.0.2) by uitsmijter.van-laarhoven.org with SMTP; 29 May 2002 07:19:19 -0000 Date: Wed, 29 May 2002 09:19:19 +0200 (CEST) From: Nick Hibma To: Greg 'groggy' Lehey Cc: FreeBSD CURRENT Mailing List Subject: Re: gdb52 patch for your .gdbinit files In-Reply-To: <20020529125101.K82424@wantadilla.lemis.com> Message-ID: <20020529091727.G231-100000@heather.van-laarhoven.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > > As you can see, the patch is trivial, so I have no clue why this wasn't > > left alone when they modified symfile.c. If I can be bothered I'll > > submit it to them. > > Hmm. Looking at this patch, it seems it's complaining about being > handed a hex value where it's looking for an address. I'd guess that > this is in the wrong place. Where does it happen in the macros? Have a look at the gdb sources in FreeBSD-CURRENT and notice the fact that they removed the call to parse_and_eval_address and rolled their own. An address like $file->address+0xabcdef should be possible, but isn't in the distribution of 5.2. After the patch it is. i've filed the patch with an already open bug report on this on GNU gdb 5.2 Nick > > Greg > > > # diff -wu gdb-5.2/gdb/symfile.c~ gdb-5.2/gdb/symfile.c > > --- gdb-5.2/gdb/symfile.c~ Tue May 28 15:51:37 2002 > > +++ gdb-5.2/gdb/symfile.c Tue May 28 15:51:06 2002 > > @@ -1546,11 +1546,15 @@ > > char *val = sect_opts[i].value; > > char *sec = sect_opts[i].name; > > > > +#ifdef 0 > > val = sect_opts[i].value; > > if (val[0] == '0' && val[1] == 'x') > > addr = strtoul (val+2, NULL, 16); > > else > > addr = strtoul (val, NULL, 10); > > +#else > > + addr = parse_and_eval_address(val); > > +#endif > > > > /* Here we store the section offsets in the order they were > > entered on the command line. */ > > -- > See complete headers for address and phone numbers > -- n_hibma@van-laarhoven.org http://www.van-laarhoven.org/ n_hibma@FreeBSD.org http://www.etla.net/~n_hibma/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message