You are viewing a plain text version of this content. The canonical link for it is here.
Posted to websh-cvs@tcl.apache.org by ro...@apache.org on 2005/12/12 18:14:04 UTC
svn commit: r356287 - in /tcl/websh/trunk/src/generic: mod_websh.c
mod_websh.h
Author: ronnie
Date: Mon Dec 12 09:13:55 2005
New Revision: 356287
URL: http://svn.apache.org/viewcvs?rev=356287&view=rev
Log:
- compatibility with Apache 2.2 (command_struct changed slightly)
Modified:
tcl/websh/trunk/src/generic/mod_websh.c
tcl/websh/trunk/src/generic/mod_websh.h
Modified: tcl/websh/trunk/src/generic/mod_websh.c
URL: http://svn.apache.org/viewcvs/tcl/websh/trunk/src/generic/mod_websh.c?rev=356287&r1=356286&r2=356287&view=diff
==============================================================================
--- tcl/websh/trunk/src/generic/mod_websh.c (original)
+++ tcl/websh/trunk/src/generic/mod_websh.c Mon Dec 12 09:13:55 2005
@@ -185,13 +185,17 @@
return basev;
}
-static const char *set_webshscript(cmd_parms * cmd, void *dummy, char *arg)
+static const char *set_webshscript(cmd_parms * cmd, void *dummy, const char *arg)
{
server_rec *s = cmd->server;
websh_server_conf *conf =
(websh_server_conf *) ap_get_module_config(s->module_config,
&websh_module);
+#ifdef APACHE2
conf->scriptName = ap_server_root_relative(cmd->pool, arg);
+#else /* APACHE2 */
+ conf->scriptName = ap_server_root_relative(cmd->pool, (char *) arg);
+#endif
return NULL;
}
@@ -227,7 +231,7 @@
#endif
static const command_rec websh_cmds[] = {
- {"WebshConfig", set_webshscript, NULL, RSRC_CONF, TAKE1,
+ {"WebshConfig", CMDFUNC set_webshscript, NULL, RSRC_CONF, TAKE1,
"the name of the main websh configuration file"},
{NULL}
};
Modified: tcl/websh/trunk/src/generic/mod_websh.h
URL: http://svn.apache.org/viewcvs/tcl/websh/trunk/src/generic/mod_websh.h?rev=356287&r1=356286&r2=356287&view=diff
==============================================================================
--- tcl/websh/trunk/src/generic/mod_websh.h (original)
+++ tcl/websh/trunk/src/generic/mod_websh.h Mon Dec 12 09:13:55 2005
@@ -29,11 +29,17 @@
#include "http_log.h"
#include "util_script.h"
-/* define APACHE2 is appropriate */
+/* define APACHE2 if appropriate */
#ifdef AP_SERVER_BASEREVISION
#define APACHE2
+#if AP_SERVER_MINORVERSION_NUMBER < 2
+#define CMDFUNC
+#else
+#define CMDFUNC (cmd_func)
+#endif
#else
#define APACHE1
+#define CMDFUNC
#endif
#ifndef APACHE2
---------------------------------------------------------------------
To unsubscribe, e-mail: websh-cvs-unsubscribe@tcl.apache.org
For additional commands, e-mail: websh-cvs-help@tcl.apache.org