From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6527 invoked by alias); 15 Feb 2006 03:05:15 -0000 Received: (qmail 6517 invoked by uid 22791); 15 Feb 2006 03:05:14 -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; Wed, 15 Feb 2006 03:05:13 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1F9CyZ-0002Gl-OR; Tue, 14 Feb 2006 22:05:07 -0500 Date: Wed, 15 Feb 2006 03:05:00 -0000 From: Daniel Jacobowitz To: Nick Roberts Cc: Bjarke Viksoe , gdb@sourceware.org Subject: Re: MI error msgs and localization Message-ID: <20060215030507.GA8700@nevyn.them.org> Mail-Followup-To: Nick Roberts , Bjarke Viksoe , gdb@sourceware.org References: <17393.12925.270558.512941@kahikatea.snap.net.nz> <17394.17519.510199.853654@kahikatea.snap.net.nz> <20060214210505.GA817@nevyn.them.org> <17394.26332.314215.498261@kahikatea.snap.net.nz> <20060214233209.GA5046@nevyn.them.org> <17394.34829.877266.50785@kahikatea.snap.net.nz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <17394.34829.877266.50785@kahikatea.snap.net.nz> User-Agent: Mutt/1.5.8i X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-02/txt/msg00152.txt.bz2 On Wed, Feb 15, 2006 at 02:46:53PM +1300, Nick Roberts wrote: > That's not quite what I said but it's a better idea as fewer changes need be > made. Better still might be to use a global variable, perhaps > mi_error_message in mi-main.c could be used. How about something like the > patch below (in mi_execute_command) to be used like this: > > mi_error_message = xstrprintf ("no-debugging-symbols"); > error(_("No debugging symbols found"); > > to give: > > &"No debugging symbols found\n" > ^error,msg="no-debugging-symbols" Please don't. If you need to pass two arguments to error, make a two-argument version :-) Passing arguments by globals is bad news. -- Daniel Jacobowitz CodeSourcery