Skip to content

Commit

Permalink
fix windows build
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk@14121 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Aug 22, 2010
1 parent d79194e commit b56a0e3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/mapserver/qgssldparser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1252,7 +1252,7 @@ QgsVectorLayer* QgsSLDParser::contourLayerFromRaster( const QDomElement& userSty
offset = contourSymbolizerElem.attribute( "offset" ).toDouble();
propertyName = contourSymbolizerElem.attribute( "propertyName" );

if ( !equidistance > 0.0 )
if ( equidistance <= 0.0 )
{
return 0;
}
Expand Down Expand Up @@ -1301,7 +1301,7 @@ QgsVectorLayer* QgsSLDParser::contourLayerFromRaster( const QDomElement& userSty
}
}

double adfFixedLevels[numberOfLevels];
double *adfFixedLevels = new double[numberOfLevels];
int nFixedLevelCount = numberOfLevels;
currentLevel = ( int )(( minValue - offset ) / equidistance + 0.5 ) * equidistance + offset;
for ( int i = 0; i < numberOfLevels; ++i )
Expand Down Expand Up @@ -1391,6 +1391,8 @@ QgsVectorLayer* QgsSLDParser::contourLayerFromRaster( const QDomElement& userSty
hLayer, 0, nElevField,
GDALTermProgress, NULL );

delete adfFixedLevels;

OGR_DS_Destroy( hDS );
GDALClose( hSrcDS );

Expand Down

0 comments on commit b56a0e3

Please sign in to comment.