From e39aae5e81000324afea9abae4788426ab4bfdb4 Mon Sep 17 00:00:00 2001 From: Daniel Morissette Date: Mon, 22 Jun 2015 09:19:36 -0400 Subject: [PATCH] Use explicit PROCESSING FORCE_DRAW_LABEL_CACHE=FLUSH to keep room for future options (#5100) --- mapdraw.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mapdraw.c b/mapdraw.c index b42aba784f..1221b90573 100644 --- a/mapdraw.c +++ b/mapdraw.c @@ -328,6 +328,8 @@ imageObj *msDrawMap(mapObj *map, int querymap) for(i=0; inumlayers; i++) { if(map->layerorder[i] != -1) { + char *force_draw_label_cache = NULL; + lp = (GET_LAYER(map, map->layerorder[i])); if(lp->postlabelcache) /* wait to draw */ @@ -391,9 +393,11 @@ imageObj *msDrawMap(mapObj *map, int querymap) } /* Flush layer cache in-between layers if requested by PROCESSING directive*/ - if (msLayerGetProcessingKey(lp, "FORCE_DRAW_LABEL_CACHE")) { + force_draw_label_cache = msLayerGetProcessingKey(lp, "FORCE_DRAW_LABEL_CACHE"); + if (force_draw_label_cache && + strncasecmp(force_draw_label_cache,"FLUSH",5)==0) { if(map->debug >= MS_DEBUGLEVEL_V) - msDebug("msDrawMap(): PROCESSING FORCE_DRAW_LABEL_CACHE found.\n"); + msDebug("msDrawMap(): PROCESSING FORCE_DRAW_LABEL_CACHE=FLUSH found.\n"); if(msDrawLabelCache(map, image) != MS_SUCCESS) { msFreeImage(image); #if defined(USE_WMS_LYR) || defined(USE_WFS_LYR)