httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Stoddard" <b...@wstoddard.com>
Subject Re: [PATCH] Don't accept more connections than workers
Date Fri, 26 Apr 2002 19:01:02 GMT

> On Fri, 26 Apr 2002, Bill Stoddard wrote:
> 
> > This is a patch to worker.c to prevent more connections from being
> > accepted than there are workers to handle them.  The accept thread
> > decrements the avail count and the workers increment the avail count. I
> > don't have a linux box handy so i cannot confirm this patch compiles.
> > Sorry.
> 
> Besides, isn't there a race condition here?  Or are you assuming ++ and --
> are atomic?

Yep, and it is a bad assumption.

Bill



Mime
View raw message