Commit f23e6d51 authored by Bas Couwenberg's avatar Bas Couwenberg

Imported Upstream version 6.4.0

parent d3dd19a5
......@@ -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})
......
......@@ -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)
......
......@@ -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);
}
......
#!/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'
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment