I figured it was a mistake to do this late at night. :(

Graham Dumpleton (JIRA) wrote:
[ http://issues.apache.org/jira/browse/MODPYTHON-131?page=comments#action_12369959 ]
Graham Dumpleton commented on MODPYTHON-131:
--------------------------------------------

In respect of:

  
http://svn.apache.org/viewcvs/httpd/mod_python/trunk/src/include/mod_python.h.in?rev=385000&r1=384999&r2=385000&view=diff

I think you probably want:

/* MUTEX_DIR can be set as a configure option
 * ./configure --with-mutex-dir=/path/to/dir
 */
#define MUTEX_DIR "@MUTEX_DIR@"

Ie., quote value of macro.

And in:

  
http://svn.apache.org/viewcvs/httpd/mod_python/trunk/src/mod_python.c?rev=385000&r1=384999&r2=385000&view=diff

you probably want:

        snprintf(fname, 255, "%s/mpmtx%d%d", MUTEX_DIR, glb->parent_pid, n);

Ie., MUTEX_DIR is substituted using %s, as macro will not be expanded in string.

This bit is going to change anyway when I add the PythonOption mod_python.mutex_directory support. I have the changes ready, but I think I'll review them in the morning rather than committing now.

I decide to do this stuff in 2 steps:
 1. configure option
 2. PythonOption mod_python.mutex_directory
    PythonOption mod_python.mutex_locks

Jim

Reply via email to