You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mod_python-commits@quetz.apache.org by gr...@apache.org on 2003/10/10 16:16:18 UTC
cvs commit: httpd-python/src mod_python.c
grisha 2003/10/10 07:16:18
Modified: . NEWS
src mod_python.c
Log:
Check for is_threaded/is_forked to avoid it trying to create 16000 mutexes
on windows.
Also added a note to NEWS that it isn't the best source of historical info.
Revision Changes Path
1.60 +8 -0 httpd-python/NEWS
Index: NEWS
===================================================================
RCS file: /home/cvs/httpd-python/NEWS,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -r1.59 -r1.60
--- NEWS 12 Feb 2003 16:10:13 -0000 1.59
+++ NEWS 10 Oct 2003 14:16:18 -0000 1.60
@@ -1,3 +1,11 @@
+
+Aug 29 2003 - 3.1.0a (Alpha) is out
+
+Mar 17 2003 - 3.0.3 is released
+
+ This file will no longer have details, since those
+ are in CVS anyway.
+
Feb 12 2003 - Added a test for req.headers_out
Fixed a bug where None was added to sys.path
1.103 +13 -5 httpd-python/src/mod_python.c
Index: mod_python.c
===================================================================
RCS file: /home/cvs/httpd-python/src/mod_python.c,v
retrieving revision 1.102
retrieving revision 1.103
diff -u -r1.102 -r1.103
--- mod_python.c 8 Oct 2003 03:48:17 -0000 1.102
+++ mod_python.c 10 Oct 2003 14:16:18 -0000 1.103
@@ -322,8 +322,10 @@
static apr_status_t init_mutexes(server_rec *s, apr_pool_t *p, py_global_config *glb)
{
- int max_threads;
- int max_procs;
+ int max_threads = 0;
+ int max_procs = 0;
+ int is_threaded = 0;
+ int is_forked = 0;
int max_clients;
int locks;
int n;
@@ -332,8 +334,14 @@
/* MAX_DAEMON_USED seems to account for MaxClients, as opposed to
MAX_DAEMONS, which is ServerLimit
*/
- ap_mpm_query(AP_MPMQ_MAX_THREADS, &max_threads);
- ap_mpm_query(AP_MPMQ_MAX_DAEMON_USED, &max_procs);
+ ap_mpm_query(AP_MPMQ_IS_THREADED, &is_threaded);
+ if (is_threaded != AP_MPMQ_NOT_SUPPORTED) {
+ ap_mpm_query(AP_MPMQ_MAX_THREADS, &max_threads);
+ }
+ ap_mpm_query(AP_MPMQ_IS_FORKED, &is_forked);
+ if (is_forked != AP_MPMQ_NOT_SUPPORTED) {
+ ap_mpm_query(AP_MPMQ_MAX_DAEMON_USED, &max_procs);
+ }
max_clients = (((!max_threads) ? 1 : max_threads) *
((!max_procs) ? 1 : max_procs));
locks = max_clients; /* XXX this is completely out of the blue */