From owner-freebsd-arch Tue Jan 14 20:34: 7 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6E7E437B405 for ; Tue, 14 Jan 2003 20:34:06 -0800 (PST) Received: from philotas.hosting.swbell.net (philotas.hosting.swbell.net [216.100.99.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4E27243EB2 for ; Tue, 14 Jan 2003 20:34:05 -0800 (PST) (envelope-from alc@imimic.com) Received: from imimic.com (adsl-216-63-78-18.dsl.hstntx.swbell.net [216.63.78.18]) by philotas.hosting.swbell.net id XAA06409; Tue, 14 Jan 2003 23:33:51 -0500 (EST) [ConcentricHost SMTP Relay 1.14] Message-ID: <3E24E4AB.5B50EBD6@imimic.com> Date: Tue, 14 Jan 2003 22:33:47 -0600 From: "Alan L. Cox" Organization: iMimic Networking, Inc. X-Mailer: Mozilla 4.8 [en] (X11; U; Linux 2.4.2 i386) X-Accept-Language: en MIME-Version: 1.0 To: Marcel Moolenaar Cc: Peter Wemm , Matthew Dillon , arch@FreeBSD.ORG Subject: Re: Virtual memory question References: <20030114041407.DDFC32A89E@canning.wemm.org> <3E239150.9FC363DD@imimic.com> <20030114100022.GA17799@dhcp01.pn.xcllnt.net> Content-Type: text/plain; charset=x-user-defined Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Marcel Moolenaar wrote: > > On Mon, Jan 13, 2003 at 10:25:52PM -0600, Alan L. Cox wrote: > > > > >From the spec (on the web page that I mentioned): > > > > "The name argument points to a string naming a shared memory object. It > > is unspecified whether the name appears in the file system and is > > visible to other functions that take pathnames as arguments." > > > > I don't think ftruncate() is necessary. The underlying shm object can > > be grown implicitly according to its mmap()ings. I do not, however, > > know of a way to shrink an shm object. > > shm_open("key", O_TRUNC|..., ...) ? > Yes, that is defined to reset the object to zero length. I was thinking about something that would only eliminate a portion of the object. Alan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message