From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26512 invoked by alias); 7 Mar 2008 19:15:00 -0000 Received: (qmail 26503 invoked by uid 22791); 7 Mar 2008 19:14:59 -0000 X-Spam-Check-By: sourceware.org Received: from bluesmobile.specifix.com (HELO bluesmobile.specifix.com) (216.129.118.140) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 07 Mar 2008 19:14:42 +0000 Received: from [127.0.0.1] (bluesmobile.specifix.com [216.129.118.140]) by bluesmobile.specifix.com (Postfix) with ESMTP id DA0A73C6D7; Fri, 7 Mar 2008 11:14:40 -0800 (PST) Subject: Re: [RFA] compilation error in remote.c on sparc-solaris From: Michael Snyder To: Daniel Jacobowitz Cc: Joel Brobecker , gdb-patches@sourceware.org In-Reply-To: <20080307190151.GA32333@caradoc.them.org> References: <20080307182744.GG3995@adacore.com> <1204916101.19253.715.camel@localhost.localdomain> <20080307190151.GA32333@caradoc.them.org> Content-Type: text/plain Date: Fri, 07 Mar 2008 19:15:00 -0000 Message-Id: <1204917280.19253.717.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.10.3 (2.10.3-7.fc7) Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-03/txt/msg00055.txt.bz2 On Fri, 2008-03-07 at 14:01 -0500, Daniel Jacobowitz wrote: > On Fri, Mar 07, 2008 at 10:55:01AM -0800, Michael Snyder wrote: > > > Variable pid is defined as follow: > > > > > > pid_t pid; > > > > > > I think it's good enough to change its type to "int". I've never seen > > > a PID that's larger than 7 digits, so an int should always be big enough. > > > In any case, that's what the pid_t structure uses for the pid. > > > > Why not just cast it? > > Because it's not a pid_t, it's an int. pid_t is the type of a process > on the host system and we're not talking to any host system processes > here. Good answer. ;-)