]> granicus.if.org Git - apache/commitdiff
* os/unix/os.h: Define AP_NEED_SET_MUTEX_PERMS.
authorJoe Orton <jorton@apache.org>
Tue, 12 Oct 2004 11:55:30 +0000 (11:55 +0000)
committerJoe Orton <jorton@apache.org>
Tue, 12 Oct 2004 11:55:30 +0000 (11:55 +0000)
* modules/mappers/mod_rewrite.c, modules/ssl/ssl_engine_mutex.c: Use
AP_NEED_SET_MUTEX_PERMS to determine whether unixd_set_*_mutex_perms
calls are necessary.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@105411 13f79535-47bb-0310-9956-ffa450edef68

modules/mappers/mod_rewrite.c
modules/ssl/ssl_engine_mutex.c
os/unix/os.h

index 717d9aab08c89dbc9809cf68087570b28ccbe26d..0511a78bf2012b72d550e300c397867f7cdaa0b9 100644 (file)
@@ -93,9 +93,8 @@
 
 #include "mod_rewrite.h"
 
-#if !defined(OS2) && !defined(WIN32) && !defined(BEOS)  && !defined(NETWARE)
+#ifdef AP_NEED_SET_MUTEX_PERMS
 #include "unixd.h"
-#define MOD_REWRITE_SET_MUTEX_PERMS /* XXX Apache should define something */
 #endif
 
 /*
@@ -2432,7 +2431,7 @@ static apr_status_t rewritelock_create(server_rec *s, apr_pool_t *p)
         return rc;
     }
 
-#ifdef MOD_REWRITE_SET_MUTEX_PERMS
+#ifdef AP_NEED_SET_MUTEX_PERMS
     rc = unixd_set_global_mutex_perms(rewrite_mapr_lock_acquire);
     if (rc != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_CRIT, rc, s,
@@ -4029,7 +4028,7 @@ static int post_config(apr_pool_t *p,
         return HTTP_INTERNAL_SERVER_ERROR;
     }
 
-#ifdef MOD_REWRITE_SET_MUTEX_PERMS
+#ifdef AP_NEED_SET_MUTEX_PERMS
     rv = unixd_set_global_mutex_perms(rewrite_log_lock);
     if (rv != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_CRIT, rv, s,
index 2756107c3235f5a8e04f3b6ea83d040b4a3bb523..9e69879a60ea8503dea3a0ca113bf1adb6ee0899 100644 (file)
@@ -28,9 +28,9 @@
                                              -- Unknown     */
 
 #include "ssl_private.h"
-#if !defined(OS2) && !defined(WIN32) && !defined(BEOS) && !defined(NETWARE)
+
+#ifdef AP_NEED_SET_MUTEX_PERMS
 #include "unixd.h"
-#define MOD_SSL_SET_MUTEX_PERMS /* XXX Apache should define something */
 #endif
 
 int ssl_mutex_init(server_rec *s, apr_pool_t *p)
@@ -57,7 +57,7 @@ int ssl_mutex_init(server_rec *s, apr_pool_t *p)
         return FALSE;
     }
 
-#ifdef MOD_SSL_SET_MUTEX_PERMS
+#ifdef AP_NEED_SET_MUTEX_PERMS
     rv = unixd_set_global_mutex_perms(mc->pMutex);
     if (rv != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_ERR, rv, s,
index a78324fba9bf4a9bd51cea2ff9edf9ceb1ee4365..bf44cd6e00b4090a3f5fa1ba9267a973d684b46b 100644 (file)
 #define PLATFORM "Unix"
 #endif
 
+/* On platforms where AP_NEED_SET_MUTEX_PERMS is defined, modules
+ * should call unixd_set_*_mutex_perms on mutexes created in the
+ * parent process. */
+#define AP_NEED_SET_MUTEX_PERMS
+
 #ifdef _OSD_POSIX
 pid_t os_fork(const char *user);
 #endif