}
c->lists = apr_array_make(c->pool, 2, sizeof(cachelist));
#if APR_HAS_THREADS
- (void)apr_lock_create(&(c->lock), APR_MUTEX, APR_INTRAPROCESS, NULL, p);
+ (void)apr_thread_mutex_create(&(c->lock), APR_THREAD_MUTEX_DEFAULT, p);
#endif
return c;
}
int found_list;
#if APR_HAS_THREADS
- apr_lock_acquire(c->lock);
+ apr_thread_mutex_lock(c->lock);
#endif
found_list = 0;
e->time = ce->time;
e->value = apr_pstrdup(c->pool, ce->value);
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return;
}
cache_tlb_replace((cachetlbentry *)l->tlb->elts,
(cacheentry *)l->entries->elts, e);
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return;
}
cache_tlb_replace((cachetlbentry *)l->tlb->elts,
(cacheentry *)l->entries->elts, e);
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return;
}
/* not reached, but when it is no problem... */
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return;
}
cacheentry *e;
#if APR_HAS_THREADS
- apr_lock_acquire(c->lock);
+ apr_thread_mutex_lock(c->lock);
#endif
for (i = 0; i < c->lists->nelts; i++) {
(cacheentry *)l->entries->elts, key);
if (e != NULL) {
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return e;
}
e = &(((cacheentry *)l->entries->elts)[j]);
if (strcmp(e->key, key) == 0) {
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return e;
}
}
}
#if APR_HAS_THREADS
- apr_lock_release(c->lock);
+ apr_thread_mutex_unlock(c->lock);
#endif
return NULL;
}