Skip to content

Commit

Permalink
- fix boundary condition for starting threads (there was a problem at…
Browse files Browse the repository at this point in the history
… least with keepwait > 0 and minthreads = 0)
  • Loading branch information
gneumann committed Sep 24, 2008
1 parent 43370bf commit b9cdd39
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nsd/queue.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
* and service threads.
*/

static const char *RCSID = "@(#) $Header: /Users/dossy/Desktop/cvs/aolserver/nsd/queue.c,v 1.44 2007/10/26 23:14:17 gneumann Exp $, compiled: " __DATE__ " " __TIME__;
static const char *RCSID = "@(#) $Header: /Users/dossy/Desktop/cvs/aolserver/nsd/queue.c,v 1.45 2008/09/24 11:25:33 gneumann Exp $, compiled: " __DATE__ " " __TIME__;

#include "nsd.h"

Expand Down Expand Up @@ -179,7 +179,7 @@ NsQueueConn(Conn *connPtr)
poolPtr->queue.wait.lastPtr = connPtr;
connPtr->nextPtr = NULL;

if (poolPtr->queue.wait.num > 0
if (poolPtr->threads.waiting == 0
&& poolPtr->threads.current < poolPtr->threads.max) {
/*
Create a new thread if no thread is waiting and the number
Expand Down

0 comments on commit b9cdd39

Please sign in to comment.