httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jkal...@apache.org
Subject svn commit: r1674222 - in /httpd/httpd/trunk: acinclude.m4 build/mkconfNW.awk include/ap_config_layout.h.in modules/dav/fs/mod_dav_fs.c
Date Fri, 17 Apr 2015 07:28:51 GMT
Author: jkaluza
Date: Fri Apr 17 07:28:50 2015
New Revision: 1674222

URL: http://svn.apache.org/r1674222
Log:
* mod_dav_fs: set default value of DavLockDB using installation layout

Modified:
    httpd/httpd/trunk/acinclude.m4
    httpd/httpd/trunk/build/mkconfNW.awk
    httpd/httpd/trunk/include/ap_config_layout.h.in
    httpd/httpd/trunk/modules/dav/fs/mod_dav_fs.c

Modified: httpd/httpd/trunk/acinclude.m4
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/acinclude.m4?rev=1674222&r1=1674221&r2=1674222&view=diff
==============================================================================
--- httpd/httpd/trunk/acinclude.m4 (original)
+++ httpd/httpd/trunk/acinclude.m4 Fri Apr 17 07:28:50 2015
@@ -43,6 +43,7 @@ AC_DEFUN(APACHE_GEN_CONFIG_VARS,[
   APACHE_SUBST(installbuilddir)
   APACHE_SUBST(runtimedir)
   APACHE_SUBST(proxycachedir)
+  APACHE_SUBST(davlockdb)
   APACHE_SUBST(other_targets)
   APACHE_SUBST(progname)
   APACHE_SUBST(prefix)
@@ -710,6 +711,7 @@ AC_DEFUN(APACHE_EXPORT_ARGUMENTS,[
   APACHE_SUBST_EXPANDED_ARG(runtimedir)
   APACHE_SUBST_EXPANDED_ARG(logfiledir)
   APACHE_SUBST_EXPANDED_ARG(proxycachedir)
+  APACHE_SUBST_EXPANDED_ARG(davlockdb)
 ])
 
 dnl 

Modified: httpd/httpd/trunk/build/mkconfNW.awk
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/build/mkconfNW.awk?rev=1674222&r1=1674221&r2=1674222&view=diff
==============================================================================
--- httpd/httpd/trunk/build/mkconfNW.awk (original)
+++ httpd/httpd/trunk/build/mkconfNW.awk Fri Apr 17 07:28:50 2015
@@ -26,12 +26,14 @@ BEGIN {
     A["runtimedir"] = "logs"
     A["errordir"] = "error"
     A["proxycachedir"] = "proxy"
+    A["davlockdb"] = "davlockdb"
 
     B["htdocsdir"] = A["ServerRoot"]"/"A["htdocsdir"]
     B["iconsdir"] = A["ServerRoot"]"/"A["iconsdir"]
     B["manualdir"] = A["ServerRoot"]"/"A["manualdir"]
     B["errordir"] = A["ServerRoot"]"/"A["errordir"]
     B["proxycachedir"] = A["ServerRoot"]"/"A["proxycachedir"]
+    B["davlockdb"] = A["ServerRoot"]"/"A["davlockdb"]
     B["cgidir"] = A["ServerRoot"]"/"A["cgidir"]
     B["logfiledir"] = A["logfiledir"]
     B["sysconfdir"] = A["sysconfdir"]

Modified: httpd/httpd/trunk/include/ap_config_layout.h.in
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/include/ap_config_layout.h.in?rev=1674222&r1=1674221&r2=1674222&view=diff
==============================================================================
--- httpd/httpd/trunk/include/ap_config_layout.h.in (original)
+++ httpd/httpd/trunk/include/ap_config_layout.h.in Fri Apr 17 07:28:50 2015
@@ -60,5 +60,7 @@
 #define DEFAULT_REL_LOGFILEDIR "@rel_logfiledir@"
 #define DEFAULT_EXP_PROXYCACHEDIR "@exp_proxycachedir@"
 #define DEFAULT_REL_PROXYCACHEDIR "@rel_proxycachedir@"
+#define DEFAULT_EXP_DAVLOCKDB "@exp_davlockdb@"
+#define DEFAULT_REL_DAVLOCKDB "@rel_davlockdb@"
 
 #endif /* AP_CONFIG_LAYOUT_H */

Modified: httpd/httpd/trunk/modules/dav/fs/mod_dav_fs.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/dav/fs/mod_dav_fs.c?rev=1674222&r1=1674221&r2=1674222&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/dav/fs/mod_dav_fs.c (original)
+++ httpd/httpd/trunk/modules/dav/fs/mod_dav_fs.c Fri Apr 17 07:28:50 2015
@@ -17,6 +17,7 @@
 #include "httpd.h"
 #include "http_config.h"
 #include "apr_strings.h"
+#include "ap_config_auto.h"
 
 #include "mod_dav.h"
 #include "repos.h"
@@ -39,7 +40,15 @@ const char *dav_get_lockdb_path(const re
 
 static void *dav_fs_create_server_config(apr_pool_t *p, server_rec *s)
 {
-    return apr_pcalloc(p, sizeof(dav_fs_server_conf));
+    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
+
+    return conf;
 }
 
 static void *dav_fs_merge_server_config(apr_pool_t *p,



Mime
View raw message