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

svn at osgeo.org svn at osgeo.org
Fri Sep 30 08:21:59 EDT 2011


Author: tbonfort
Date: 2011-09-30 05:21:59 -0700 (Fri, 30 Sep 2011)
New Revision: 12609

Modified:
   trunk/mapserver/mapcache/src/service_wms.c
Log:
fix segfault on multi-layer wms request on non-exisiting layer



Modified: trunk/mapserver/mapcache/src/service_wms.c
===================================================================
--- trunk/mapserver/mapcache/src/service_wms.c	2011-09-30 11:04:43 UTC (rev 12608)
+++ trunk/mapserver/mapcache/src/service_wms.c	2011-09-30 12:21:59 UTC (rev 12609)
@@ -541,6 +541,11 @@
                 * this step is not done for the first tileset as we have already performed it
                 */
                tileset = mapcache_configuration_get_tileset(config,key);
+               if (!tileset) {
+                  errcode = 404;
+                  errmsg = apr_psprintf(ctx->pool,"received wms request with invalid layer %s", key);
+                  goto proxies;
+               }
                int i;
                grid_link = NULL;
                for(i=0;i<tileset->grid_links->nelts;i++){



More information about the mapserver-commits mailing list