From owner-freebsd-doc Fri Sep 27 12:47:57 2002 Delivered-To: freebsd-doc@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 224E937B404 for ; Fri, 27 Sep 2002 12:47:56 -0700 (PDT) Received: from rylos.atmos.colostate.edu (rylos.atmos.colostate.edu [129.82.48.47]) by mx1.FreeBSD.org (Postfix) with ESMTP id 064EB43E6E for ; Fri, 27 Sep 2002 12:47:55 -0700 (PDT) (envelope-from tarcieri@atmos.colostate.edu) Received: from rylos.atmos.colostate.edu (tarcieri@localhost [127.0.0.1]) by rylos.atmos.colostate.edu (8.12.3/8.12.3) with ESMTP id g8RJlPsw088580 for ; Fri, 27 Sep 2002 13:47:25 -0600 (MDT) (envelope-from tarcieri@atmos.colostate.edu) Received: from localhost (tarcieri@localhost) by rylos.atmos.colostate.edu (8.12.3/8.12.3/Submit) with ESMTP id g8RJlO1K088577 for ; Fri, 27 Sep 2002 13:47:25 -0600 (MDT) X-Authentication-Warning: rylos.atmos.colostate.edu: tarcieri owned process doing -bs Date: Fri, 27 Sep 2002 13:47:24 -0600 (MDT) From: Tony Arcieri To: freebsd-doc@freebsd.org Subject: Error on manpage for shmctl() Message-ID: <20020927134016.D88535-100000@rylos.atmos.colostate.edu> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-doc@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org I noticed that the documented behavior for how FreeBSD handles IPC_RMID to be rather discontiguous with other platforms. On my manpage for shmctl(), at least the version included with FreeBSD 4.6, the behavior is described as follows: IPC_RMID Removes the segment from the system. The removal will not take effect until all processes having attached the segment have exited; however, once the IPC_RMID operation has taken place, no further processes will be allowed to attach the segment. This would be less than ideal, as it would then be impossible to reclaim shared memory which was no longer needed by any processes attached to it without said processes exiting, and any unused shared memory would essentially be leaked. I've tested it myself, and shared memory segments do appear to be reclaimed (at least, according to ipcs) after shmctl() is called with IPC_RMID and all processes have detached the shared memory segment with shmdt(). So, either the memory isn't reclaimed and merely doesn't show up in ipcs (in which case this behavior should probably be documented) or the manpage is wrong. I'd like to know what the answer is in either case. I'm not subscribed to this list so please CC replies to me. Tony Arcieri To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message