+2001-03-12 Alex Graveley <alex@ximian.com>
+
+ * src/soup-core/soup-server.c (soup_server_get_handler): avoid
+ leading and trailing quotes. If an exact match is not found,
+ lookup based only on methodname not uri#methodnmae.
+
+ * src/soup-core/soup-apache.c (soup_apache_handler): compile
+ without warnings.
+
+ * configure.in (AC_OUTPUT): chmod +x soup_apacheConf.sh
+
2001-03-09 Alex Graveley <alex@ximian.com>
* src/soup-wsdl/wsdl-parse.c (wsdl_parse): set definitions = NULL
SoupServerHandler *
soup_server_get_handler (const gchar *methodname)
{
- GSList *iter = soup_server_handlers;
+ GSList *iter;
+ gchar *name;
+ gint len;
g_return_val_if_fail (methodname != NULL, NULL);
+ name = g_strdup (methodname);
+ g_strstrip (name);
+ len = strlen (name);
+
+ /* Strip quotes */
+ if (name [0] == '"' && name [len] == '"') {
+ name [len--] = '\0';
+ name++;
+ }
+
+ RETRY_MATCH:
for (iter = soup_server_handlers; iter; iter = iter->next) {
SoupServerHandler *hand = iter->data;
- if (!strcmp (hand->methodname, methodname))
+ if (!strcmp (hand->methodname, name)) {
+ g_free (name);
return hand;
+ }
}
+
+ /* Try again without the URI */
+ methodname = strchr (name, '#');
+ if (methodname && strlen (name) > 1) {
+ name++;
+ goto RETRY_MATCH;
+ }
+
+ g_free (name);
return NULL;
}