From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32373 invoked by alias); 15 Oct 2009 02:17:01 -0000 Received: (qmail 32363 invoked by uid 22791); 15 Oct 2009 02:17:01 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.33.17) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 15 Oct 2009 02:16:55 +0000 Received: from zps35.corp.google.com (zps35.corp.google.com [172.25.146.35]) by smtp-out.google.com with ESMTP id n9F2Gqha011301 for ; Thu, 15 Oct 2009 03:16:52 +0100 Received: from ey-out-1920.google.com (eyb5.prod.google.com [10.208.2.5]) by zps35.corp.google.com with ESMTP id n9F2GnZ3011756 for ; Wed, 14 Oct 2009 19:16:49 -0700 Received: by ey-out-1920.google.com with SMTP id 5so116251eyb.24 for ; Wed, 14 Oct 2009 19:16:48 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.89.14 with SMTP id b14mr3187466wef.76.1255573008768; Wed, 14 Oct 2009 19:16:48 -0700 (PDT) In-Reply-To: <200910142329.06920.pedro@codesourcery.com> References: <20091013184120.30A5776761@ppluzhnikov.mtv.corp.google.com> <200910142216.46073.pedro@codesourcery.com> <8ac60eac0910141428t428f0accqa16008c53cac5c16@mail.gmail.com> <200910142329.06920.pedro@codesourcery.com> Date: Thu, 15 Oct 2009 02:17:00 -0000 Message-ID: Subject: Re: [patch] Fix for internal-error: linux_nat_post_attach_wait: Assertion `pid == new_pid && WIFSTOPPED (status)' failed. From: Doug Evans To: Pedro Alves Cc: Paul Pluzhnikov , gdb-patches@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-System-Of-Record: true 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: 2009-10/txt/msg00327.txt.bz2 On Wed, Oct 14, 2009 at 3:29 PM, Pedro Alves wrote: > Something else I noticed: > >> + =A0 =A0 =A0 =A0 int signo =3D WTERMSIG (status); > > Should be: > > =A0 =A0 =A0 =A0enum target_signal signo =3D target_signal_from_host (WTER= MSIG (status)); > >> + >> + =A0 =A0 =A0 =A0 target_terminal_ours (); >> + =A0 =A0 =A0 =A0 target_mourn_inferior (); >> + =A0 =A0 =A0 =A0 error (_("During startup program terminated with signa= l %s, %s."), >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0target_signal_to_name (signo), >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0target_signal_to_string (signo)); > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ^^^^^^^^^^^^^^^^^^^^^^^ > > because these functions take a target independent gdb > signal (TARGET_SIGNAL_...). =A0Yes, it's confusing. These kinds of errors should be caught by the compilation system or languag= e. Then it wouldn't be confusing at all.