From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10396 invoked by alias); 21 Jun 2003 22:31:45 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 7991 invoked from network); 21 Jun 2003 22:31:00 -0000 Received: from unknown (HELO crack.them.org) (146.82.138.56) by sources.redhat.com with SMTP; 21 Jun 2003 22:31:00 -0000 Received: from dsl093-172-017.pit1.dsl.speakeasy.net ([66.93.172.17] helo=nevyn.them.org ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 19Tqtk-0006YJ-00 for ; Sat, 21 Jun 2003 17:31:52 -0500 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 19Tqsr-0008B4-00 for ; Sat, 21 Jun 2003 18:30:57 -0400 Date: Sat, 21 Jun 2003 22:31:00 -0000 From: Daniel Jacobowitz To: gdb-patches@sources.redhat.com Subject: PR gdb/260: variables not expanded on the add-symbol-file command line Message-ID: <20030621223056.GB31184@nevyn.them.org> Mail-Followup-To: gdb-patches@sources.redhat.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.1i X-SW-Source: 2003-06/txt/msg00675.txt.bz2 This PR gets reported pretty regularly. Since the command line overhaul I was hoping to do never materialized, does anyone object to this patch to fix the specific problem in add-symbol-file? I believe the patch is simple enough to have no copyright issues. The problem is that the code tries to parse and 0x directly, and does not accept convenience variables. ----- Forwarded message from Nick Hibma ----- Date: 28 May 2002 19:28:01 -0000 From: Nick Hibma Subject: Re: gdb/260: variables not expanded on the add-symbol-file command line To: nobody@sources.redhat.com Cc: gdb-prs@sources.redhat.com, Reply-To: Nick Hibma The following reply was made to PR gdb/260; it has been noted by GNATS. From: Nick Hibma To: nobody@sources.redhat.com, phil@off.net, gdb-gnats@sources.redhat.com, gdb-prs@sources.redhat.com Cc: Subject: Re: gdb/260: variables not expanded on the add-symbol-file command line Date: Tue, 28 May 2002 21:23:53 +0200 http://sources.redhat.com/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gdb&pr=260 The following patch fixes this (in 5.2) (note that it also removes a duplicate initialisation): # diff -wu symfile.c.orig symfile.c --- symfile.c.orig Tue May 28 15:51:37 2002 +++ symfile.c Tue May 28 21:21:04 2002 @@ -1546,11 +1546,7 @@ char *val = sect_opts[i].value; char *sec = sect_opts[i].name; - val = sect_opts[i].value; - if (val[0] == '0' && val[1] == 'x') - addr = strtoul (val+2, NULL, 16); - else - addr = strtoul (val, NULL, 10); + addr = parse_and_eval_address(val); /* Here we store the section offsets in the order they were entered on the command line. */ ----- End forwarded message ----- -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer