#include "scoreboard.h"
#include <signal.h>
+#include <limits.h> /* for INT_MAX */
/*
* Actual definitions of config globals
/* TODO: Switch to a system where threads reuse the results from earlier
poll calls - manoj */
while (1) {
- workers_may_exit |= (ap_max_requests_per_child != 0) && (requests_this_child <= 0);
+ workers_may_exit |= (requests_this_child <= 0);
if (workers_may_exit) break;
(void) ap_update_child_status(process_slot, thread_slot, SERVER_READY,
}
ap_max_requests_per_child = atoi(arg);
+
+ /* a value of zero means infinity. The following removes a conditional
+ * from worker_thread's hot path
+ */
+
+ if (!ap_max_requests_per_child) {
+ ap_max_requests_per_child = INT_MAX;
+ }
return NULL;
}