Skip to content
Permalink
Browse files
Fix for memory leak in getFeatureInfo (bug #2990)
git-svn-id: http://svn.osgeo.org/qgis/trunk@14219 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Sep 11, 2010
1 parent 1cd2d14 commit 52e58915de1fdf0ea4ad3aa8757ddbd046a01fd4
Showing with 2 additions and 0 deletions.
  1. +2 −0 src/mapserver/qgswmsserver.cpp
@@ -455,13 +455,15 @@ int QgsWMSServer::getFeatureInfo( QDomDocument& result )

if ( configureMapRender( outputImage ) != 0 )
{
delete outputImage;
return 2;
}

//find out the current scale denominater and set it to the SLD parser
QgsScaleCalculator scaleCalc(( outputImage->logicalDpiX() + outputImage->logicalDpiY() ) / 2 , mMapRenderer->destinationSrs().mapUnits() );
QgsRectangle mapExtent = mMapRenderer->extent();
mConfigParser->setScaleDenominator( scaleCalc.calculate( mapExtent, outputImage->width() ) );
delete outputImage; //no longer needed for feature info

//read FEATURE_COUNT
int featureCount = 1;

0 comments on commit 52e5891

Please sign in to comment.