From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21899 invoked from network); 14 Jun 2004 16:01:40 -0000 Received: from thor.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.86) by ns1.primenet.com.au with SMTP; 14 Jun 2004 16:01:40 -0000 Received: (qmail 2663 invoked from network); 14 Jun 2004 16:01:20 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 14 Jun 2004 16:01:20 -0000 Received: (qmail 23568 invoked by alias); 14 Jun 2004 16:01:12 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 20044 Received: (qmail 23558 invoked from network); 14 Jun 2004 16:01:12 -0000 Received: from thor.dotsrc.org (HELO a.mx.sunsite.dk) (qmailr@130.225.247.86) by sunsite.dk with SMTP; 14 Jun 2004 16:01:09 -0000 Received: (qmail 2325 invoked from network); 14 Jun 2004 16:01:08 -0000 Received: from mail36.messagelabs.com (193.109.254.211) by a.mx.sunsite.dk with SMTP; 14 Jun 2004 16:01:07 -0000 X-VirusChecked: Checked X-Env-Sender: okiddle@yahoo.co.uk X-Msg-Ref: server-2.tower-36.messagelabs.com!1087228840!6952387 X-StarScan-Version: 5.2.10; banners=-,-,- X-Originating-IP: [158.234.9.163] Received: (qmail 4992 invoked from network); 14 Jun 2004 16:00:40 -0000 Received: from iris.logica.co.uk (158.234.9.163) by server-2.tower-36.messagelabs.com with SMTP; 14 Jun 2004 16:00:40 -0000 Received: from trentino.logica.co.uk ([158.234.142.61]) by iris.logica.co.uk (8.12.3/8.12.3/Debian -4) with ESMTP id i5EG0dUI014247 for ; Mon, 14 Jun 2004 17:00:39 +0100 Received: from trentino.logica.co.uk (localhost [127.0.0.1]) by trentino.logica.co.uk (Postfix) with ESMTP id 6B5717858660 for ; Mon, 14 Jun 2004 17:59:55 +0200 (CEST) X-VirusChecked: Checked X-StarScan-Version: 5.0.7; banners=.,-,- In-reply-to: <200406141521.i5EFLolC019193@news01.csr.com> From: Oliver Kiddle References: <200406141521.i5EFLolC019193@news01.csr.com> To: Zsh workers Subject: Re: setting resource limits Date: Mon, 14 Jun 2004 17:59:55 +0200 Message-ID: <29023.1087228795@trentino.logica.co.uk> X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: * X-Spam-Status: No, hits=1.6 required=6.0 tests=BAYES_60 autolearn=no version=2.63 X-Spam-Hits: 1.6 Peter wrote: > A much nicer way of doing it is with an explicit option to give the > number of the limit. This is more consistent with normal ulimit > behaviour. Yes, this does look better. Cheers. It should probably produce an error for a negative number instead of defaulting to the file size limit. The old code initialises res to -1 twice then checks for it at the end. I'd have thought it could just be initialised to RLIMIT_FSIZE with the <0 test producing an error. Is it worth doing the same for the limit and unlimit builtins too? Oliver