From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17217 invoked by alias); 28 May 2003 20:21: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 17175 invoked from network); 28 May 2003 20:21:43 -0000 Received: from unknown (HELO zenia.red-bean.com) (12.223.225.216) by sources.redhat.com with SMTP; 28 May 2003 20:21:43 -0000 Received: from zenia.red-bean.com (localhost.localdomain [127.0.0.1]) by zenia.red-bean.com (8.12.5/8.12.5) with ESMTP id h4SKUWFq004227; Wed, 28 May 2003 15:30:32 -0500 Received: (from jimb@localhost) by zenia.red-bean.com (8.12.5/8.12.5/Submit) id h4SKUVGd004223; Wed, 28 May 2003 15:30:31 -0500 To: gdb-patches@sources.redhat.com Subject: RFA: don't cast last argument to ptrace From: Jim Blandy Date: Wed, 28 May 2003 20:21:00 -0000 Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2003-05/txt/msg00515.txt.bz2 I've committed this to the PPC64 Linux branch, but I think it should be considered for the trunk as well. 2003-05-14 James Blandy * ppc-linux-nat.c (store_altivec_registers): Don't cast fourth argument to ptrace to int; the system headers should give it the right type, and pointers don't fit in ints on powerpc64-*-*. *** gdb/ppc-linux-nat.c.~1.2.~ Wed May 14 11:37:19 2003 --- gdb/ppc-linux-nat.c Wed May 14 18:29:11 2003 *************** *** 428,434 **** int ret; gdb_vrregset_t regs; ! ret = ptrace (PTRACE_GETVRREGS, tid, 0, (int) ®s); if (ret < 0) { if (errno == EIO) --- 428,434 ---- int ret; gdb_vrregset_t regs; ! ret = ptrace (PTRACE_GETVRREGS, tid, 0, ®s); if (ret < 0) { if (errno == EIO) *************** *** 441,447 **** fill_vrregset (®s); ! if (ptrace (PTRACE_SETVRREGS, tid, 0, (int) ®s) < 0) perror_with_name ("Couldn't write AltiVec registers"); } --- 441,447 ---- fill_vrregset (®s); ! if (ptrace (PTRACE_SETVRREGS, tid, 0, ®s) < 0) perror_with_name ("Couldn't write AltiVec registers"); }