Permalink
Browse files

Fix build when USE_ICONV is not defined

  • Loading branch information...
rouault committed Aug 5, 2015
1 parent 0fc850b commit 32d2aa75a7afd300e5cdc67a3c569299ef3cdbea
Showing with 1 addition and 1 deletion.
  1. +1 −1 mapstring.c
@@ -2203,14 +2203,14 @@ int msLayerEncodeShapeAttributes( layerObj *layer, shapeObj *shape) {
if( !layer->encoding || !*layer->encoding || !strcasecmp(layer->encoding, "UTF-8"))
return MS_SUCCESS;
#ifdef USE_ICONV
cd = iconv_open("UTF-8", layer->encoding);
if(cd == (iconv_t)-1) {
msSetError(MS_IDENTERR, "Encoding not supported by libiconv (%s).",
"msGetEncodedString()", layer->encoding);
return MS_FAILURE;
}
#ifdef USE_ICONV
for(i=0;i <shape->numvalues; i++) {
if(!shape->values[i] || (len = strlen(shape->values[i]))==0) {
continue; /* Nothing to do */

0 comments on commit 32d2aa7

Please sign in to comment.