From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28443 invoked by alias); 7 Feb 2014 15:10:27 -0000 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 Received: (qmail 28426 invoked by uid 89); 7 Feb 2014 15:10:27 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-4.4 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 07 Feb 2014 15:10:26 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s17FANbT021670 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 7 Feb 2014 10:10:23 -0500 Received: from host2.jankratochvil.net (ovpn-116-25.ams2.redhat.com [10.36.116.25]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id s17FAJ5f029642 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Fri, 7 Feb 2014 10:10:22 -0500 Date: Fri, 07 Feb 2014 15:10:00 -0000 From: Jan Kratochvil To: "Maciej W. Rozycki" Cc: gdb-patches@sourceware.org Subject: Re: [patch] testsuite: Fix "ERROR: no fileid for" Message-ID: <20140207151018.GA20010@host2.jankratochvil.net> References: <20140206205814.GA18495@host2.jankratochvil.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes X-SW-Source: 2014-02/txt/msg00201.txt.bz2 On Thu, 06 Feb 2014 23:09:25 +0100, Maciej W. Rozycki wrote: > Can you provide a more elaborate log of your test session? $ echo 'set gdbserver_reconnect_p 1' >test.exp;runtest test.exp > What are the exact conditions for this problem to trigger? If GDB does not run and the testsuite tries to close down it errors. > I'm asking because I fear your change could defeat the purpose of the > commit you referred to if there's a catastrophic failure causing GDB to > crash while running gdb.base/solib-disc.exp -- in such a case an instance > of gdbserver would stay behind running, ruining the remaining part of the > test suite in environments where only a single TCP port is available for > the RSP connection. If GDB has crashed then gdb_spawn_id still exists (although it does not work). So my patch does not change anything. And also currently it will leave the stale gdbserver running anyway. In general if gdb_spawn_id does not exist then send_gdb + gdb_expect just do not make sense anyway. So this patch just prevents the error in such case. The killing of stale gdbserver could be improved multiple ways (also as suggested by Pedro in the original thread) but that is IMO outside of the scope of this patch. Apparently if there is no good response from GDB then gdb_finish() should try to call gdb_start just to kill that gdbserver, IIUC. Thanks, Jan