[mapserver-commits] r11621 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Wed Apr 27 14:17:33 EDT 2011


Author: tamas
Date: 2011-04-27 11:17:33 -0700 (Wed, 27 Apr 2011)
New Revision: 11621

Modified:
   trunk/mapserver/HISTORY.TXT
   trunk/mapserver/mapunion.c
Log:
Fix for the styleitem handling with union layer (#3674)

Modified: trunk/mapserver/HISTORY.TXT
===================================================================
--- trunk/mapserver/HISTORY.TXT	2011-04-27 16:18:45 UTC (rev 11620)
+++ trunk/mapserver/HISTORY.TXT	2011-04-27 18:17:33 UTC (rev 11621)
@@ -15,6 +15,8 @@
 Current Version (SVN trunk): 
 ---------------------------- 
 
+- Fix for the styleitem handling with union layer (#3674)
+
 - Fixed mindsitance label test to check layer indexes. (#3851)
 
 - Fixed segmentation fault in PHP/MapScript and improved the php object method calls (#3730)

Modified: trunk/mapserver/mapunion.c
===================================================================
--- trunk/mapserver/mapunion.c	2011-04-27 16:18:45 UTC (rev 11620)
+++ trunk/mapserver/mapunion.c	2011-04-27 18:17:33 UTC (rev 11621)
@@ -398,11 +398,11 @@
         srclayer = &layerinfo->layers[layerinfo->layerIndex];
         while (srclayer->vtable->LayerNextShape(srclayer, shape) == MS_SUCCESS)
         {
-            if(strcasecmp(layer->styleitem, "AUTO") != 0) 
+            if(layer->styleitem) 
             {
                 /* need to retrieve the source layer classindex if styleitem AUTO is set */
                 layerinfo->classIndex = msShapeGetClass(srclayer, layer->map, shape, layerinfo->classgroup, layerinfo->nclasses);
-                if((layerinfo->classIndex == -1) || (srclayer->class[layerinfo->classIndex]->status == MS_OFF)) 
+                if(layerinfo->classIndex < 0 || layerinfo->classIndex >= srclayer->numclasses) 
                 {
                     // this shape is not visible, skip it
                     msFreeShape(shape);



More information about the mapserver-commits mailing list