[mapserver-commits] r7854 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Thu Aug 14 15:22:49 EDT 2008


Author: dmorissette
Date: 2008-08-14 15:22:48 -0400 (Thu, 14 Aug 2008)
New Revision: 7854

Modified:
   trunk/mapserver/mapfile.c
Log:
Fixed leak of styleObj (#2728)

Modified: trunk/mapserver/mapfile.c
===================================================================
--- trunk/mapserver/mapfile.c	2008-08-14 18:16:17 UTC (rev 7853)
+++ trunk/mapserver/mapfile.c	2008-08-14 19:22:48 UTC (rev 7854)
@@ -1615,7 +1615,7 @@
   /* return(-1); */
   /* } */
   /* } */
-
+  
   return(0); 
 }
 
@@ -2154,7 +2154,9 @@
   /* reset styles */
   for(i=0; i<class->numstyles; i++) {
     if(class->styles[i] != NULL) {
-      freeStyle(class->styles[i]);
+      if( freeStyle(class->styles[i]) == MS_SUCCESS ) {
+        msFree(class->styles[i]);
+      }
       class->styles[i] = NULL;
     }
   }



More information about the mapserver-commits mailing list