From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5303 invoked by alias); 20 Dec 2001 17:11:27 -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 5277 invoked from network); 20 Dec 2001 17:11:24 -0000 Received: from unknown (HELO cygnus.com) (205.180.230.5) by sources.redhat.com with SMTP; 20 Dec 2001 17:11:24 -0000 Received: from rtl.cygnus.com (cse.cygnus.com [205.180.230.236]) by runyon.cygnus.com (8.8.7-cygnus/8.8.7) with ESMTP id JAA27668; Thu, 20 Dec 2001 09:11:21 -0800 (PST) Received: (from ezannoni@localhost) by rtl.cygnus.com (8.11.2/8.11.0) id fBKGOEh01999; Thu, 20 Dec 2001 11:24:14 -0500 X-Authentication-Warning: localhost.localdomain: ezannoni set sender to ezannoni@cygnus.com using -f From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15394.4270.245910.8192@localhost.localdomain> Date: Thu, 20 Dec 2001 09:11:00 -0000 To: gdb-patches@sources.redhat.com CC: kevinb@cygnus.com Subject: [RFA] rs6000-nat.c fetch_register error condition. X-Mailer: VM 7.00 under Emacs 20.7.1 X-SW-Source: 2001-12/txt/msg00521.txt.bz2 I am trying to break down the Altivec patch in smaller pieces that don't require a ptrace interface. I thought this bit had been approved by Kevin in http://sources.redhat.com/ml/gdb-patches/2001-11/msg00564.html but it wasn't. Kevin, OK to commit? Elena 2001-12-20 Elena Zannoni * rs6000-nat.c (fetch_register): Don't error out unless the register number is really bogus. Index: rs6000-nat.c =================================================================== RCS file: /cvs/uberbaum/gdb/rs6000-nat.c,v retrieving revision 1.18 diff -u -r1.18 rs6000-nat.c --- rs6000-nat.c 2001/12/19 14:14:52 1.18 +++ rs6000-nat.c 2001/12/20 16:57:30 @@ -206,9 +206,12 @@ /* Bogus register number. */ else if (regno > LAST_UISA_SP_REGNUM) - fprintf_unfiltered (gdb_stderr, - "gdb error: register no %d not implemented.\n", - regno); + { + if (regno >= NUM_REGS) + fprintf_unfiltered (gdb_stderr, + "gdb error: register no %d not implemented.\n", + regno); + } /* Fixed-point registers. */ else