1
0
mirror of https://github.com/apache/httpd.git synced 2025-08-08 15:02:10 +03:00

tweaks to r883540:

watchdog: use better mutex type name
  ldap/digest: use same FOO_mutex_type variable name as other modules
    for easier searching


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@883708 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jeff Trawick
2009-11-24 14:47:55 +00:00
parent 8b224c767f
commit 0644e027f4
3 changed files with 11 additions and 11 deletions

View File

@@ -180,8 +180,8 @@ static unsigned long *opaque_cntr;
static apr_time_t *otn_counter; /* one-time-nonce counter */ static apr_time_t *otn_counter; /* one-time-nonce counter */
static apr_global_mutex_t *client_lock = NULL; static apr_global_mutex_t *client_lock = NULL;
static apr_global_mutex_t *opaque_lock = NULL; static apr_global_mutex_t *opaque_lock = NULL;
static const char *client_lock_type = "authdigest-client"; static const char *client_mutex_type = "authdigest-client";
static const char *opaque_lock_type = "authdigest-opaque"; static const char *opaque_mutex_type = "authdigest-opaque";
static const char *client_shm_filename; static const char *client_shm_filename;
#define DEF_SHMEM_SIZE 1000L /* ~ 12 entries */ #define DEF_SHMEM_SIZE 1000L /* ~ 12 entries */
@@ -322,7 +322,7 @@ static int initialize_tables(server_rec *s, apr_pool_t *ctx)
client_list->tbl_len = num_buckets; client_list->tbl_len = num_buckets;
client_list->num_entries = 0; client_list->num_entries = 0;
sts = ap_global_mutex_create(&client_lock, client_lock_type, NULL, s, ctx, 0); sts = ap_global_mutex_create(&client_lock, client_mutex_type, NULL, s, ctx, 0);
if (sts != APR_SUCCESS) { if (sts != APR_SUCCESS) {
log_error_and_cleanup("failed to create lock (client_lock)", sts, s); log_error_and_cleanup("failed to create lock (client_lock)", sts, s);
return !OK; return !OK;
@@ -338,7 +338,7 @@ static int initialize_tables(server_rec *s, apr_pool_t *ctx)
} }
*opaque_cntr = 1UL; *opaque_cntr = 1UL;
sts = ap_global_mutex_create(&opaque_lock, opaque_lock_type, NULL, s, ctx, 0); sts = ap_global_mutex_create(&opaque_lock, opaque_mutex_type, NULL, s, ctx, 0);
if (sts != APR_SUCCESS) { if (sts != APR_SUCCESS) {
log_error_and_cleanup("failed to create lock (opaque_lock)", sts, s); log_error_and_cleanup("failed to create lock (opaque_lock)", sts, s);
return !OK; return !OK;
@@ -366,9 +366,9 @@ static int pre_init(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *ptemp)
{ {
apr_status_t rv; apr_status_t rv;
rv = ap_mutex_register(pconf, client_lock_type, NULL, APR_LOCK_DEFAULT, 0); rv = ap_mutex_register(pconf, client_mutex_type, NULL, APR_LOCK_DEFAULT, 0);
if (rv == APR_SUCCESS) { if (rv == APR_SUCCESS) {
rv = ap_mutex_register(pconf, opaque_lock_type, NULL, APR_LOCK_DEFAULT, rv = ap_mutex_register(pconf, opaque_mutex_type, NULL, APR_LOCK_DEFAULT,
0); 0);
} }
if (rv != APR_SUCCESS) { if (rv != APR_SUCCESS) {

View File

@@ -66,7 +66,7 @@ static wd_server_conf_t *wd_server_conf = NULL;
static apr_interval_time_t wd_interval = AP_WD_TM_INTERVAL; static apr_interval_time_t wd_interval = AP_WD_TM_INTERVAL;
static int wd_interval_set = 0; static int wd_interval_set = 0;
static int mpm_is_forked = AP_MPMQ_NOT_SUPPORTED; static int mpm_is_forked = AP_MPMQ_NOT_SUPPORTED;
static const char *wd_proc_mutex_type = "wd-proc"; static const char *wd_proc_mutex_type = "watchdog-callback";
static apr_status_t wd_worker_cleanup(void *data) static apr_status_t wd_worker_cleanup(void *data)
{ {

View File

@@ -64,7 +64,7 @@
#define AP_LDAP_CHASEREFERRALS_ON 1 #define AP_LDAP_CHASEREFERRALS_ON 1
module AP_MODULE_DECLARE_DATA ldap_module; module AP_MODULE_DECLARE_DATA ldap_module;
static const char *ldap_cache_lock_type = "ldap-cache"; static const char *ldap_cache_mutex_type = "ldap-cache";
#define LDAP_CACHE_LOCK() do { \ #define LDAP_CACHE_LOCK() do { \
if (st->util_ldap_cache_lock) \ if (st->util_ldap_cache_lock) \
@@ -2521,7 +2521,7 @@ static int util_ldap_pre_config(apr_pool_t *pconf, apr_pool_t *plog,
{ {
apr_status_t result; apr_status_t result;
result = ap_mutex_register(pconf, ldap_cache_lock_type, NULL, result = ap_mutex_register(pconf, ldap_cache_mutex_type, NULL,
APR_LOCK_DEFAULT, 0); APR_LOCK_DEFAULT, 0);
if (result != APR_SUCCESS) { if (result != APR_SUCCESS) {
return result; return result;
@@ -2580,7 +2580,7 @@ static int util_ldap_post_config(apr_pool_t *p, apr_pool_t *plog,
} }
result = ap_global_mutex_create(&st->util_ldap_cache_lock, result = ap_global_mutex_create(&st->util_ldap_cache_lock,
ldap_cache_lock_type, NULL, s, p, 0); ldap_cache_mutex_type, NULL, s, p, 0);
if (result != APR_SUCCESS) { if (result != APR_SUCCESS) {
return result; return result;
} }
@@ -2682,7 +2682,7 @@ static void util_ldap_child_init(apr_pool_t *p, server_rec *s)
ap_log_error(APLOG_MARK, APLOG_CRIT, sts, s, ap_log_error(APLOG_MARK, APLOG_CRIT, sts, s,
"Failed to initialise global mutex %s in child process %" "Failed to initialise global mutex %s in child process %"
APR_PID_T_FMT ".", APR_PID_T_FMT ".",
ldap_cache_lock_type, getpid()); ldap_cache_mutex_type, getpid());
} }
} }