[mapserver-commits] r12206 - trunk/mapserver/mapcache/src

svn at osgeo.org svn at osgeo.org
Fri Aug 26 07:07:07 EDT 2011


Author: tbonfort
Date: 2011-08-26 04:07:06 -0700 (Fri, 26 Aug 2011)
New Revision: 12206

Modified:
   trunk/mapserver/mapcache/src/services.c
Log:
look for some more default location for apr-config
thomas.bonfort | 2011-01-06 20:17:04 +0100 (Thu, 06 Jan 2011)

Modified: trunk/mapserver/mapcache/src/services.c
===================================================================
--- trunk/mapserver/mapcache/src/services.c	2011-08-26 11:07:02 UTC (rev 12205)
+++ trunk/mapserver/mapcache/src/services.c	2011-08-26 11:07:06 UTC (rev 12206)
@@ -565,7 +565,6 @@
 
 void geocache_service_dispatch_request(geocache_context *ctx, geocache_request **request, char *pathinfo, apr_table_t *params, geocache_cfg *config) {
    int i;
-   geocache_service *service = NULL;
    
    /* skip empty pathinfo */
    if(!pathinfo) {
@@ -583,12 +582,14 @@
    }
    
    for(i=0;i<GEOCACHE_SERVICES_COUNT;i++) {
+      /* loop through the services that have been configured */
       int prefixlen;
-      /* loop through the services that have been configured */
+      geocache_service *service = NULL;
       service = config->services[i];
       prefixlen = strlen(service->url_prefix);
       if(!service) continue; /* skip an unconfigured service */
       if(strncmp(service->url_prefix,pathinfo, prefixlen)) continue; /*skip a service who's prefix does not correspond */
+      if(*(pathinfo+prefixlen)!='/' && *(pathinfo+prefixlen)!='\0') continue; /*we matched the prefix but there are trailing characters*/
       pathinfo += prefixlen; /* advance pathinfo to after the service prefix */
       service->parse_request(ctx,request,pathinfo,params,config);
       GC_CHECK_ERROR(ctx);



More information about the mapserver-commits mailing list