[SCM] mapserver branch, upstream, updated. upstream/6.4.0_rc1-1-gf23e6d5

Bas Couwenberg sebastic at xs4all.nl
Tue Sep 17 15:49:08 UTC 2013


The following commit has been merged in the upstream branch:
commit f23e6d51dce7c83e6315ac215f3847fa0e180453
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date:   Tue Sep 17 17:13:58 2013 +0200

    Imported Upstream version 6.4.0

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8c5ef1c..268e05d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -12,7 +12,7 @@ include(CheckCSourceCompiles)
 set (MapServer_VERSION_MAJOR 6)
 set (MapServer_VERSION_MINOR 4)
 set (MapServer_VERSION_REVISION 0)
-set (MapServer_VERSION_SUFFIX "-rc1")
+set (MapServer_VERSION_SUFFIX "")
 
 set(TARGET_VERSION_MAJOR ${MapServer_VERSION_MAJOR})
 set(TARGET_VERSION_MINOR ${MapServer_VERSION_MINOR})
diff --git a/INSTALL.CMAKE b/INSTALL.CMAKE
index 4a1c42e..638fa1c 100644
--- a/INSTALL.CMAKE
+++ b/INSTALL.CMAKE
@@ -66,6 +66,7 @@ mkdir build
 cd build
 ccmake ..
 ## follow instructions, fix dependency issues
+make
 
 Options and Dependencies
 ........................
@@ -140,7 +141,7 @@ of these can be enabled or disabled by passing "-DWITH_XXX=0" or "-DWITH_XXX=1"
  - option(WITH_WFS "Enable WFS Server support (requires PROJ and OGR support)" ON)
  - option(WITH_WCS "Enable WCS Server support (requires PROJ and GDAL support)" ON)
  - option(WITH_LIBXML2 "Choose if libxml2 support should be built in (used for sos, wcs 1.1,2.0 and wfs 1.1)" ON)
- - option(WITH_THREADS "Choose if a thread-safe version of libmapserver should be built (only recommended for some mapscripts)" OFF)
+ - option(WITH_THREAD_SAFETY "Choose if a thread-safe version of libmapserver should be built (only recommended for some mapscripts)" OFF)
  - option(WITH_GIF "Enable GIF support (for PIXMAP loading)" ON)
  - option(WITH_PYTHON "Enable Python mapscript support" OFF)
  - option(WITH_PHP "Enable Python mapscript support" OFF)
diff --git a/mapcontour.c b/mapcontour.c
index 12ae259..15f3129 100644
--- a/mapcontour.c
+++ b/mapcontour.c
@@ -108,8 +108,8 @@ static void msContourLayerInfoInitialize(layerObj *layer)
   clinfo->ogrLayer.debug = layer->debug;
   clinfo->ogrLayer.connectiontype = MS_OGR;
   clinfo->ogrLayer.name = msStrdup(layer->name);
-  clinfo->ogrLayer.connection = (char*)msSmallMalloc(strlen(layer->name)+13);
-  sprintf(clinfo->ogrLayer.connection, "__%s_CONTOUR__", layer->name);
+  clinfo->ogrLayer.connection = (char*)msSmallMalloc(strlen(clinfo->ogrLayer.name)+13);
+  sprintf(clinfo->ogrLayer.connection, "__%s_CONTOUR__", clinfo->ogrLayer.name);
   clinfo->ogrLayer.units = layer->units;
 }
 
@@ -322,8 +322,8 @@ static int msContourLayerReadRaster(layerObj *layer, rectObj rect)
     
     if (copyRect.minx >= copyRect.maxx || copyRect.miny >= copyRect.maxy) {
       if (layer->debug)
-        msDebug("msContourLayerReadRaster(): Error in overlap calculation.\n");
-      return MS_FAILURE;
+        msDebug("msContourLayerReadRaster(): No overlap.\n");
+      return MS_SUCCESS;
     }
 
     /*
@@ -365,7 +365,7 @@ static int msContourLayerReadRaster(layerObj *layer, rectObj rect)
     {
       if (layer->debug)
         msDebug("msContourLayerReadRaster(): input window too small, or no apparent overlap between map view and this window(1).\n");
-      return MS_FAILURE;
+      return MS_SUCCESS;
     }
 
     /* Target buffer size */
@@ -375,7 +375,7 @@ static int msContourLayerReadRaster(layerObj *layer, rectObj rect)
     if (dst_xsize == 0 || dst_ysize == 0) {
       if (layer->debug)
         msDebug("msContourLayerReadRaster(): no apparent overlap between map view and this window(2).\n");
-      return MS_FAILURE;
+      return MS_SUCCESS;
     }
 
     if (layer->debug)
@@ -522,6 +522,10 @@ static int msContourLayerGenerateContour(layerObj *layer)
     return MS_FAILURE;
   }
 
+  if (!clinfo->hDS) { /* no overlap */
+    return MS_SUCCESS;
+  }
+  
   hBand = GDALGetRasterBand(clinfo->hDS, 1);
   if (hBand == NULL)
   {
@@ -655,12 +659,14 @@ int msContourLayerOpen(layerObj *layer)
   if (msContourLayerGenerateContour(layer) != MS_SUCCESS)
     return MS_FAILURE;
 
-  GDALClose(clinfo->hDS);
-  clinfo->hDS = NULL;  
-  free(clinfo->buffer);
+  if (clinfo->hDS) {
+    GDALClose(clinfo->hDS);
+    clinfo->hDS = NULL;  
+    free(clinfo->buffer);
+  }
 
   /* Open our virtual ogr layer */
-  if (msLayerOpen(&clinfo->ogrLayer) != MS_SUCCESS)
+  if (clinfo->hOGRDS && (msLayerOpen(&clinfo->ogrLayer) != MS_SUCCESS))
     return MS_FAILURE;
   
   return MS_SUCCESS;
@@ -681,7 +687,8 @@ int msContourLayerClose(layerObj *layer)
     msDebug("Entering msContourLayerClose().\n");
 
   if (clinfo) {
-    msConnPoolRelease(&clinfo->ogrLayer, clinfo->hOGRDS);
+    if (clinfo->hOGRDS)
+      msConnPoolRelease(&clinfo->ogrLayer, clinfo->hOGRDS);
 
     msLayerClose(&clinfo->ogrLayer);
     
@@ -718,6 +725,7 @@ int msContourLayerGetItems(layerObj *layer)
 
 int msContourLayerWhichShapes(layerObj *layer, rectObj rect, int isQuery)
 {
+  int i;
   rectObj newRect;
   contourLayerInfo *clinfo = (contourLayerInfo *) layer->layerinfo;
 
@@ -744,7 +752,9 @@ int msContourLayerWhichShapes(layerObj *layer, rectObj rect, int isQuery)
 #endif
 
   /* regenerate the raster io */
-  msConnPoolRelease(&clinfo->ogrLayer, clinfo->hOGRDS);
+  if (clinfo->hOGRDS)
+    msConnPoolRelease(&clinfo->ogrLayer, clinfo->hOGRDS);
+  
   msLayerClose(&clinfo->ogrLayer);
   
   /* Open the raster source */
@@ -755,16 +765,24 @@ int msContourLayerWhichShapes(layerObj *layer, rectObj rect, int isQuery)
   if (msContourLayerGenerateContour(layer) != MS_SUCCESS)
     return MS_FAILURE;
 
-  GDALClose(clinfo->hDS);
-  clinfo->hDS = NULL;
-  free(clinfo->buffer);  
+  if (clinfo->hDS) {
+    GDALClose(clinfo->hDS);
+    clinfo->hDS = NULL;
+    free(clinfo->buffer);
+  }
+  
+  if (!clinfo->hOGRDS) /* no overlap */
+    return MS_DONE;
   
   /* Open our virtual ogr layer */
   if (msLayerOpen(&clinfo->ogrLayer) != MS_SUCCESS)
     return MS_FAILURE;
 
   clinfo->ogrLayer.numitems = layer->numitems;
-  clinfo->ogrLayer.items = CSLDuplicate(layer->items); 
+  clinfo->ogrLayer.items = (char **) msSmallMalloc(sizeof(char *)*layer->numitems);
+  for (i=0; i<layer->numitems;++i) {
+    clinfo->ogrLayer.items[i] = msStrdup(layer->items[i]);
+  }
 
   return msLayerWhichShapes(&clinfo->ogrLayer, rect, isQuery);
 }
diff --git a/release-notes.sh b/release-notes.sh
new file mode 100755
index 0000000..659e181
--- /dev/null
+++ b/release-notes.sh
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+commitdiff=$1
+
+if test -z $commitdiff; then
+   echo "usage: $0 startcommit..endcommit"
+   exit
+fi
+
+git --no-pager  log --no-merges  --pretty=format:'%s (%an) : `%h <https://github.com/mapserver/mapserver/commit/%H>`__' $commitdiff | gsed  's!#\([0-9]\+\)! `#\1 <https://github.com/mapserver/mapserver/issues/\1>`__ !g'
+

-- 
Packaging for MapServer



More information about the Pkg-grass-devel mailing list