[mapserver-commits] r9315 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Thu Sep 17 15:45:27 EDT 2009


Author: tamas
Date: 2009-09-17 15:45:26 -0400 (Thu, 17 Sep 2009)
New Revision: 9315

Modified:
   trunk/mapserver/HISTORY.TXT
   trunk/mapserver/shp2img.c
Log:
Fixed shp2img not to cause a crash when the map couldn't be loaded

Modified: trunk/mapserver/HISTORY.TXT
===================================================================
--- trunk/mapserver/HISTORY.TXT	2009-09-17 15:17:05 UTC (rev 9314)
+++ trunk/mapserver/HISTORY.TXT	2009-09-17 19:45:26 UTC (rev 9315)
@@ -14,6 +14,8 @@
 Current Version (SVN trunk):
 ----------------------------
 
+- Fixed shp2img not to cause a crash when the map couldn't be loaded
+
 - Fix problem with overflowing shape->index for (most) query modes (#2850)
 
 - Useful error message when PK is missing and data is subselect (#3124)

Modified: trunk/mapserver/shp2img.c
===================================================================
--- trunk/mapserver/shp2img.c	2009-09-17 15:17:05 UTC (rev 9314)
+++ trunk/mapserver/shp2img.c	2009-09-17 19:45:26 UTC (rev 9315)
@@ -128,12 +128,12 @@
  
     if(strcmp(argv[i],"-m") == 0) {
       map = msLoadMap(argv[i+1], NULL);
-      msApplyDefaultSubstitutions(map);
       if(!map) {
 	msWriteError(stderr);
         msCleanup();
 	exit(0);
       }
+      msApplyDefaultSubstitutions(map);
     }
   }
 



More information about the mapserver-commits mailing list