summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoe Orton <jorton@apache.org>2018-10-05 17:26:14 +0200
committerJoe Orton <jorton@apache.org>2018-10-05 17:26:14 +0200
commitaa9c1ea3f16d430c1d2218eeb050c3ea0dc6cee1 (patch)
treec34257ef3fc96cae0d5e13e98a6b9044c9de34b2
parentDefine "state directory" for storing persistent child-writable state, (diff)
downloadapache2-aa9c1ea3f16d430c1d2218eeb050c3ea0dc6cee1.tar.xz
apache2-aa9c1ea3f16d430c1d2218eeb050c3ea0dc6cee1.zip
* modules/dav/fs/mod_dav_fs.c (dav_fs_create_server_config): Use
statedir-relative default lock database path. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1842931 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--modules/dav/fs/mod_dav_fs.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/dav/fs/mod_dav_fs.c b/modules/dav/fs/mod_dav_fs.c
index c49d7045b5..50267cad66 100644
--- a/modules/dav/fs/mod_dav_fs.c
+++ b/modules/dav/fs/mod_dav_fs.c
@@ -32,6 +32,10 @@ typedef struct {
extern module AP_MODULE_DECLARE_DATA dav_fs_module;
+#ifndef DEFAULT_DAV_LOCKDB
+#define DEFAULT_DAV_LOCKDB "davlockdb"
+#endif
+
const char *dav_get_lockdb_path(const request_rec *r)
{
dav_fs_server_conf *conf;
@@ -43,12 +47,8 @@ const char *dav_get_lockdb_path(const request_rec *r)
static void *dav_fs_create_server_config(apr_pool_t *p, server_rec *s)
{
dav_fs_server_conf *conf = apr_pcalloc(p, sizeof(dav_fs_server_conf));
-#ifdef DEFAULT_EXP_DAVLOCKDB
- conf->lockdb_path = DEFAULT_EXP_DAVLOCKDB;
- if (*conf->lockdb_path == '\0') {
- conf->lockdb_path = NULL;
- }
-#endif
+
+ conf->lockdb_path = ap_state_dir_relative(p, DEFAULT_DAV_LOCKDB);
return conf;
}