From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30245 invoked by alias); 20 Mar 2013 18:04:46 -0000 Mailing-List: contact cygwin-developers-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-developers-owner@cygwin.com Mail-Followup-To: cygwin-developers@cygwin.com Received: (qmail 30207 invoked by uid 89); 20 Mar 2013 18:04:39 -0000 X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.1 Received: from aquarius.hirmke.de (HELO calimero.vinschen.de) (217.91.18.234) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 20 Mar 2013 18:04:37 +0000 Received: by calimero.vinschen.de (Postfix, from userid 500) id 7F5F35203F8; Wed, 20 Mar 2013 19:04:34 +0100 (CET) Date: Wed, 20 Mar 2013 18:04:00 -0000 From: Corinna Vinschen To: cygwin-developers@cygwin.com Subject: Re: Update RLIM_INFINITY for x86_64? Message-ID: <20130320180434.GA27969@calimero.vinschen.de> Reply-To: cygwin-developers@cygwin.com Mail-Followup-To: cygwin-developers@cygwin.com References: <5149F6F3.5030605@cornell.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <5149F6F3.5030605@cornell.edu> User-Agent: Mutt/1.5.21 (2010-09-15) X-SW-Source: 2013-03/txt/msg00101.txt.bz2 On Mar 20 13:50, Ken Brown wrote: > My understanding is that RLIM_INFINITY is usually equal to (or very > close to) SIZE_MAX on Posix-like systems. If this is right, then I > think we need something like the attached patch. > > Ken > --- resource.h.orig 2013-03-20 12:20:21.569382900 -0400 > +++ resource.h 2013-03-20 11:54:53.900144800 -0400 > @@ -34,7 +34,11 @@ > #define RLIMIT_NLIMITS 7 /* upper bound of RLIMIT_* defines */ > #define RLIM_NLIMITS RLIMIT_NLIMITS > > +#ifdef __x86_64__ > +#define RLIM_INFINITY (0xffffffffffffffffUL) > +#else > #define RLIM_INFINITY (0xffffffffUL) > +#endif > #define RLIM_SAVED_MAX RLIM_INFINITY > #define RLIM_SAVED_CUR RLIM_INFINITY Good catch, thank you! I simplified this to a single definition #define RLIM_INFINITY (~0UL) and checked it in under your name. Thanks, Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat