Return-Path: Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 27679 invoked by uid 500); 10 Jun 2001 22:32:52 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list dev@apr.apache.org Received: (qmail 27667 invoked from network); 10 Jun 2001 22:32:51 -0000 Date: Mon, 11 Jun 2001 00:31:53 +0200 From: Luke Kenneth Casson Leighton To: Ben Laurie Cc: Cliff Woolley , dev@apr.apache.org Subject: Re: cvs commit: apr/memory/unix apr_sms.c Message-ID: <20010611003153.D2726@angua.rince.de> Mail-Followup-To: Ben Laurie , Cliff Woolley , dev@apr.apache.org References: <20010606214902.91508.qmail@apache.org> <20010607161123.M13785@angua.rince.de> <3B225E1D.B5F26BB6@algroup.co.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.4i In-Reply-To: <3B225E1D.B5F26BB6@algroup.co.uk>; from ben@algroup.co.uk on Sat, Jun 09, 2001 at 06:34:21PM +0100 X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N On Sat, Jun 09, 2001 at 06:34:21PM +0100, Ben Laurie wrote: > Luke Kenneth Casson Leighton wrote: > > > > uh... i thought i should point out: the original proposal > > i recommended for the sms locking routine should pass > > in the area of memory to be locked and its length, > > and ditto for the unlocking. > > +1. > > > in this way, let's say you do mmap on a file, you can > > use posix locking as the implementation of the locking > > on the memory. > > > > [or can you? i dunno, for sure :) ] > > I believe so. > > > and, if the argument is NULL, it means ' do a Global Lock'. > > > > if the unlock() argument is NULL, it means 'do a Global > > Unlock - i.e. free all locks'. > > And if the locking mechanism doesn't support regions? (This is > particularly important if you allow unlocking of subregions). The > obvious answer being that we implement them in APR, of course. well, that is what made me think that perhaps a separate lock and lock_region be done, such that one or other cold be supported. or, you mandate providing locking, emulating regions by ... errr.... providing ref-counting on a global lock (yuck!) hm, that don't work. nope: have to do the lock and lock_region, then have a means for Users to detect that a lock_region function is available / supported. you know, this is all tending to suggest having a 'apr_sms_get_features()' fn, returning a bitfield of supported features. ... ? luke