From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20631 invoked from network); 8 Oct 2004 13:16:10 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 8 Oct 2004 13:16:10 -0000 Received: (qmail 41339 invoked from network); 8 Oct 2004 13:16:04 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 8 Oct 2004 13:16:04 -0000 Received: (qmail 12743 invoked by alias); 8 Oct 2004 13:15:52 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 20466 Received: (qmail 12733 invoked from network); 8 Oct 2004 13:15:51 -0000 Received: from unknown (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 8 Oct 2004 13:15:51 -0000 Received: (qmail 40660 invoked from network); 8 Oct 2004 13:14:52 -0000 Received: from lhuumrelay3.lnd.ops.eu.uu.net (62.189.58.19) by a.mx.sunsite.dk with SMTP; 8 Oct 2004 13:14:49 -0000 Received: from MAILSWEEPER01.csr.com (mailhost1.csr.com [62.189.183.235]) by lhuumrelay3.lnd.ops.eu.uu.net (8.11.0/8.11.0) with ESMTP id i98DEkv24062 for ; Fri, 8 Oct 2004 13:14:47 GMT Received: from EXCHANGE02.csr.com (unverified [192.168.137.45]) by MAILSWEEPER01.csr.com (Content Technologies SMTPRS 4.3.12) with ESMTP id for ; Fri, 8 Oct 2004 14:13:43 +0100 Received: from news01.csr.com ([192.168.143.38]) by EXCHANGE02.csr.com with Microsoft SMTPSVC(5.0.2195.6713); Fri, 8 Oct 2004 14:17:00 +0100 Received: from news01.csr.com (localhost.localdomain [127.0.0.1]) by news01.csr.com (8.12.11/8.12.11) with ESMTP id i98DEhhq007928 for ; Fri, 8 Oct 2004 14:14:43 +0100 Received: from csr.com (pws@localhost) by news01.csr.com (8.12.11/8.12.11/Submit) with ESMTP id i98DEf3F007925 for ; Fri, 8 Oct 2004 14:14:43 +0100 Message-Id: <200410081314.i98DEf3F007925@news01.csr.com> X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: zsh-workers@sunsite.dk Subject: Re: bug with for and time In-reply-to: <20041007152539.GA27081@dan.emsphone.com> References: <41616CDC.8020701@codesourcery.com> <200410041610.i94GAl92005952@news01.csr.com> <20041005113848.6f3715bd@buddha.localdomain.de> <20041005181820.GC30419@dan.emsphone.com> <20041006134818.089f5218@buddha.localdomain.de> <200410061706.i96H6LTO010315@news01.csr.com> <20041006175328.GB87634@dan.emsphone.com> <200410070937.i979bRaK027278@news01.csr.com> <20041007152539.GA27081@dan.emsphone.com> Date: Fri, 08 Oct 2004 14:14:41 +0100 From: Peter Stephenson X-OriginalArrivalTime: 08 Oct 2004 13:17:00.0332 (UTC) FILETIME=[182956C0:01C4AD39] X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=0.0 required=6.0 tests=none autolearn=no version=2.63 X-Spam-Hits: 0.0 Dan Nelson wrote: > I did some mailinglist searches, and back in 1999, workers-2526 says > that getrusage was removed because it wasn't POSIX and the autoconf > test was too complex. There's another issue... we used to get the usage for a child by calling wait3(), which can set a struct rusage. (Modern systems have wait4, which allows you to wait for a particular PID, but it looks like we don't actually use that anyway.) However, this isn't part of the latest standards. So the only standardised way of doing it is to call getrusage and subtract all appropriate elements. With some (maximum value), you can't actually tell for sure whether it's applicable to the last child or not. Maybe we should prefer wait3(), which is widely available, and do the best we can elsewhere, but it's not ideal. Still, both wait3() and the additional rusage elements came from BSD; maybe I can rely on either both or neither being available and skip the case where we can't tie usage to individual processes. > One AC_CHECK_MEMBERS call with 14 arguments is all that's needed, plus the > appropriate #if defined checks around each resource in the TIMEFMT > expansion code. This bit I can easily get working. -- Peter Stephenson Software Engineer CSR Ltd., Science Park, Milton Road, Cambridge, CB4 0WH, UK Tel: +44 (0)1223 692070 ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. www.mimesweeper.com **********************************************************************