From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31222 invoked by alias); 23 Oct 2012 03:25:12 -0000 Received: (qmail 31154 invoked by uid 22791); 23 Oct 2012 03:25:09 -0000 X-SWARE-Spam-Status: No, hits=-3.7 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,TW_YQ X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 23 Oct 2012 03:25:02 +0000 Received: from svr-orw-fem-01.mgc.mentorg.com ([147.34.98.93]) by relay1.mentorg.com with esmtp id 1TQV6z-0006Lj-Ph from Yao_Qi@mentor.com for gdb-patches@sourceware.org; Mon, 22 Oct 2012 20:25:01 -0700 Received: from SVR-ORW-FEM-05.mgc.mentorg.com ([147.34.97.43]) by svr-orw-fem-01.mgc.mentorg.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Mon, 22 Oct 2012 20:25:01 -0700 Received: from qiyao.dyndns.org.com (147.34.91.1) by svr-orw-fem-05.mgc.mentorg.com (147.34.97.43) with Microsoft SMTP Server id 14.1.289.1; Mon, 22 Oct 2012 20:25:00 -0700 From: Yao Qi To: Subject: [PATCH] Really release IPC resources in info-os.exp Date: Tue, 23 Oct 2012 03:25:00 -0000 Message-ID: <1350962676-18529-1-git-send-email-yao@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain 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: 2012-10/txt/msg00399.txt.bz2 Hi, I find test case gdb.base/info-os.exp fails on our testing servers, because of error "No space left on device". After I remove these IPC resources manually, fails disappear. On my build server, after each execution of info-os.exp, the number of IPC resources increases by 3, $ make check RUNTESTFLAGS='--target_board=unix info-os.exp' $ ipcs | grep yqi | wc -l 15 $ make check RUNTESTFLAGS='--target_board=unix info-os.exp' $ ipcs | grep yqi | wc -l 18 The end of info-os.exp and info-os.c takes care of releasing them, but it is still not enough. In current info-os.exp, dejagnu sends gdb "continue" and tears down gdb process. It is possible that gdb and inferior is terminated before the end of info-os.c (releasing IPC resources) is executed. This patch force GDB to wait until inferior is exited to make sure IPC resources is really released. With this patch applied, after each execution of info-os.exp, the number of IPC resources is not changed. Is it OK? gdb/testsuite: 2012-10-23 Yao Qi * gdb.base/info-os.exp: Resume the inferior until it exits. --- gdb/testsuite/gdb.base/info-os.exp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/gdb/testsuite/gdb.base/info-os.exp b/gdb/testsuite/gdb.base/info-os.exp index 541f03b..4200067 100644 --- a/gdb/testsuite/gdb.base/info-os.exp +++ b/gdb/testsuite/gdb.base/info-os.exp @@ -176,4 +176,4 @@ expect_multiline "info os msg" "$msgkey +$msqid +666 .*" "get message queues" # The SysV IPC primitives linger on after the creating process is killed # unless they are destroyed explicitly, so allow the test program to tidy # up after itself. -send_gdb "continue\n" +gdb_test "continue" ".*exited.*" -- 1.7.7.6