*/
#define DBM_FILE_MODE ( APR_UREAD | APR_UWRITE | APR_GREAD | APR_WREAD )
-#define DEFAULT_DBM_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-dbm-"
+#define DEFAULT_DBM_PREFIX "socache-dbm-"
/* ### this should use apr_dbm_usednames. */
#if !defined(DBM_FILE_SUFFIX_DIR) && !defined(DBM_FILE_SUFFIX_PAG)
const char *path = apr_pstrcat(p, DEFAULT_DBM_PREFIX, namespace,
NULL);
- ctx->data_file = ap_server_root_relative(p, path);
+ ctx->data_file = ap_runtime_dir_relative(p, path);
if (ctx->data_file == NULL) {
ap_log_error(APLOG_MARK, APLOG_ERR, 0, s, APLOGNO(00803)
#define SHMCB_MAX_SIZE (64 * 1024 * 1024)
-#define DEFAULT_SHMCB_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-shmcb-"
+#define DEFAULT_SHMCB_PREFIX "socache-shmcb-"
#define DEFAULT_SHMCB_SUFFIX ".cache"
const char *path = apr_pstrcat(p, DEFAULT_SHMCB_PREFIX, namespace,
DEFAULT_SHMCB_SUFFIX, NULL);
- ctx->data_file = ap_server_root_relative(p, path);
+ ctx->data_file = ap_runtime_dir_relative(p, path);
}
/* Use anonymous shm by default, fall back on name-based. */
#define DEFAULT_LOGBYTES 10385760
#define DEFAULT_BUFBYTES 1024
-#define DEFAULT_SOCKET DEFAULT_REL_RUNTIMEDIR "/cgisock"
+#define DEFAULT_SOCKET "cgisock"
#define CGI_REQ 1
#define SSI_REQ 2
procnew->err = procnew->in = procnew->out = NULL;
apr_pool_userdata_set((const void *)procnew, userdata_key,
apr_pool_cleanup_null, main_server->process->pool);
+ return ret;
}
else {
procnew = data;
total_modules++;
parent_pid = getpid();
- tmp_sockname = ap_server_root_relative(p, sockname);
+ tmp_sockname = ap_runtime_dir_relative(p, sockname);
if (strlen(tmp_sockname) > sizeof(server_addr->sun_path) - 1) {
tmp_sockname[sizeof(server_addr->sun_path)] = '\0';
ap_log_error(APLOG_MARK, APLOG_ERR, 0, main_server, APLOGNO(01254)
/* Make sure the pid is appended to the sockname */
sockname = ap_append_pid(cmd->pool, arg, ".");
- sockname = ap_server_root_relative(cmd->pool, sockname);
+ sockname = ap_runtime_dir_relative(cmd->pool, sockname);
if (!sockname) {
return apr_pstrcat(cmd->pool, "Invalid ScriptSock path",
}
}
else {
- use_dir = ap_server_root_relative(pconf, DEFAULT_REL_RUNTIMEDIR);
+ use_dir = ap_runtime_dir_relative(pconf, "");
}
chdir(use_dir);
/* initialize default mutex configuration */
def = apr_pcalloc(p, sizeof *def);
def->mech = APR_LOCK_DEFAULT;
- def->dir = DEFAULT_REL_RUNTIMEDIR;
+ def->dir = ap_runtime_dir_relative(p, "");
apr_hash_set(mxcfg_by_type, "default", APR_HASH_KEY_STRING, def);
}