From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21434 invoked by alias); 1 Dec 2003 17:26:08 -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 21426 invoked from network); 1 Dec 2003 17:26:07 -0000 Received: from unknown (HELO localhost.redhat.com) (66.30.197.194) by sources.redhat.com with SMTP; 1 Dec 2003 17:26:07 -0000 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id A63DE2B8F; Mon, 1 Dec 2003 12:26:07 -0500 (EST) Message-ID: <3FCB79AF.6010405@gnu.org> Date: Mon, 01 Dec 2003 17:26:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.2) Gecko/20030820 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "Dhananjay R. Deshpande" Cc: Andrew Cagney , Michael Snyder , gdb-patches@sources.redhat.com Subject: Re: H8300 Patch - Fix GDB crash problem when object file of different H8 cpu is loaded References: <69595093233BB547BB70CF5E492B63F202FBC77C@sohm.kpit.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2003-12/txt/msg00016.txt.bz2 Basicly ok (and thanks), can you just change these functions: > +int > +is_h8300smode (void) > +{ > + return gdbarch_bfd_arch_info (current_gdbarch)->mach == bfd_mach_h8300sx > + || gdbarch_bfd_arch_info (current_gdbarch)->mach == bfd_mach_h8300sxn > + || gdbarch_bfd_arch_info (current_gdbarch)->mach == bfd_mach_h8300s > + || gdbarch_bfd_arch_info (current_gdbarch)->mach == bfd_mach_h8300sn; > +} > + so that the "current_gdbarch" is passed explicitly as a parameter making the call: is_h8300smode (current_gdbarch) That will save someone the effort of having to add the parameter later. It still leaves the task of replacing current_gdbarch with something more local at the call site, but lets leave that as a later pass. With that change it's ok to commit. Can you also please, as a separate patch (don't forget changelog and to post it), add yourself to the write after approval list. Andrew