httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Richards <p.richa...@elsevier.co.uk>
Subject Re: help with a concurrency locking problem?
Date Fri, 24 May 1996 09:54:50 GMT
In reply to sameer@c2.org who said
> 
> 	Thanks for all the input. Do you know if intel has the atomic
> test & set? (I'm on a pentium.) This gets a bit complex. I should
> actually just add some debugging to see if the concurency ever
> actually happens.

You can't rely on this fact in your code since you're at the mercy of the
compiler. You should always do locking operations via atomic kernel
functions since you don't have a problem then since the process will
always runs until the lock is set. I think fcntl should be safe to
use to do this and it handles records as well.

-- 
  Paul Richards. Originative Solutions Ltd.  (Netcraft Ltd. contractor)
  Elsevier Science TIS online journal project.
  Email: p.richards@elsevier.co.uk
  Phone: 0370 462071 (Mobile), +44 (0)1865 843155

Mime
View raw message