- fixed Web_InterpCfg_AP and Web_InterpClassCfg_AP: NULL terminate
param lists (Thanks to Mark Johnston for the report and patch)
diff --git a/CHANGES b/CHANGES
index ab4cbc6..1d457bc 100644
--- a/CHANGES
+++ b/CHANGES
@@ -19,6 +19,9 @@
Trunk
-----
+- Fixed Web_InterpCfg_AP and Web_InterpClassCfg_AP in modwebsh_ap.c
+ (potential segfault for invalid parameters)
+
- Improved apachetests to deal with included conf files
- Parse x-www-form-urlencoded forms also if charset is given
diff --git a/src/ChangeLog b/src/ChangeLog
index 86a0984..257faf4 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,8 @@
+2011-08-15 Brunner Ronnie <ronnie.brunner@netcetera.ch>
+ * src/generic/modwebsh_ap.c:
+ - fixed Web_InterpCfg_AP and Web_InterpClassCfg_AP: NULL terminate
+ param lists (Thanks to Mark Johnston for the report and patch)
+
2011-05-05 Brunner Ronnie <ronnie.brunner@netcetera.ch>
* src/apachetests/apachetest.tcl, src/apachetests/runtests.tcl:
- Get around some double quote issues for the server conf file
diff --git a/src/generic/modwebsh_ap.c b/src/generic/modwebsh_ap.c
index ad47cfb..7d43d1a 100644
--- a/src/generic/modwebsh_ap.c
+++ b/src/generic/modwebsh_ap.c
@@ -197,10 +197,17 @@
"numrequests",
"starttime",
"lastusedtime",
- "retire"
+ "retire",
+ NULL
};
+
enum params
- { INTERP_REQUESTS, INTERP_START, INTERP_LASTUSED, INTERP_RETIRE };
+ {
+ INTERP_REQUESTS,
+ INTERP_START,
+ INTERP_LASTUSED,
+ INTERP_RETIRE
+ };
WebInterp *webInterp = (WebInterp *) clientData;
@@ -281,10 +288,18 @@
WebInterpClass *webInterpClass = NULL;
int index;
- static TCLCONST char *classParams[] = { "maxttl",
- "maxidletime", "maxrequests" };
+ static TCLCONST char *classParams[] = {
+ "maxttl",
+ "maxidletime",
+ "maxrequests",
+ NULL
+ };
enum params
- { CLASS_TTL, CLASS_IDLETIME, CLASS_REQUESTS };
+ {
+ CLASS_TTL,
+ CLASS_IDLETIME,
+ CLASS_REQUESTS
+ };
websh_server_conf *conf = (websh_server_conf *) clientData;