diff options
Diffstat (limited to 'apps/JAWS/PROTOTYPE/JAWS/Server.cpp')
-rw-r--r-- | apps/JAWS/PROTOTYPE/JAWS/Server.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/apps/JAWS/PROTOTYPE/JAWS/Server.cpp b/apps/JAWS/PROTOTYPE/JAWS/Server.cpp index 8b4eb8d0699..0b9dfa0c501 100644 --- a/apps/JAWS/PROTOTYPE/JAWS/Server.cpp +++ b/apps/JAWS/PROTOTYPE/JAWS/Server.cpp @@ -107,6 +107,21 @@ JAWS_Server::open (JAWS_Pipeline_Handler *protocol, db->task ()->next (protocol); + // prime the acceptor if appropriate + if (this->dispatch_ == 1) + { +#if defined (ACE_WIN32) || defined (ACE_HAS_AIO_CALLS) + + int n = this->nthreads_; + if (this->concurrency_ == 1) + n = 1; + + for (int i = 0; i < n * this->ratio_ - n; i++) + db->task ()->put (db); + +#endif /* defined (ACE_WIN32) */ + } + // The message block should contain an INET_Addr, and call the // io->accept (INET_Addr) method! |