From: William A. Rowe Jr Date: Mon, 22 Dec 2008 21:34:59 +0000 (+0000) Subject: ditto hack from mpm_default.h X-Git-Tag: 2.3.1~70 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7266c515bb73ce08df6b6131b46cb794786616ab;p=thirdparty%2Fapache%2Fhttpd.git ditto hack from mpm_default.h git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@728787 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/cache/mod_socache_dbm.c b/modules/cache/mod_socache_dbm.c index e7ffbbbfe2a..28864008402 100644 --- a/modules/cache/mod_socache_dbm.c +++ b/modules/cache/mod_socache_dbm.c @@ -53,7 +53,12 @@ struct ap_socache_instance_t { */ #define SSL_DBM_FILE_MODE ( APR_UREAD | APR_UWRITE | APR_GREAD | APR_WREAD ) +/* Check for definition of DEFAULT_REL_RUNTIMEDIR */ +#ifndef DEFAULT_REL_RUNTIMEDIR +#define DEFAULT_DBM_PREFIX "logs/socache-dbm-" +#else #define DEFAULT_DBM_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-dbm-" +#endif /* ### this should use apr_dbm_usednames. */ #if !defined(SSL_DBM_FILE_SUFFIX_DIR) && !defined(SSL_DBM_FILE_SUFFIX_PAG) diff --git a/modules/cache/mod_socache_shmcb.c b/modules/cache/mod_socache_shmcb.c index 549e305e92e..ceacc4e5c9b 100644 --- a/modules/cache/mod_socache_shmcb.c +++ b/modules/cache/mod_socache_shmcb.c @@ -31,6 +31,16 @@ #define SHMCB_MAX_SIZE (64 * 1024 * 1024) +/* Check for definition of DEFAULT_REL_RUNTIMEDIR */ +#ifndef DEFAULT_REL_RUNTIMEDIR +#define DEFAULT_SHMCB_PREFIX "logs/socache-shmcb-" +#else +#define DEFAULT_SHMCB_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-shmcb-" +#endif + +#define DEFAULT_SHMCB_SUFFIX ".cache" + + /* * This shared memory based SSL session cache implementation was * originally written by Geoff Thorpe for C2Net @@ -307,9 +317,6 @@ static const char *socache_shmcb_create(ap_socache_instance_t **context, return NULL; } -#define DEFAULT_SHMCB_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-shmcb-" -#define DEFAULT_SHMCB_SUFFIX ".cache" - static apr_status_t socache_shmcb_init(ap_socache_instance_t *ctx, const char *namespace, const struct ap_socache_hints *hints,