Skip to content
Permalink
Browse files
Fix Coverity divide by 0 error
  • Loading branch information
nyalldawson committed Apr 17, 2017
1 parent 952bc02 commit e4d6bbfe7614e9ed3e09ceadd80d337019647a35
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/server/services/wms/qgswmsrenderer.cpp
@@ -1219,7 +1219,7 @@ namespace QgsWms
{
mapExtent.invert();
}
if ( !mapExtent.isEmpty() && height > 0 )
if ( !mapExtent.isEmpty() && height > 0 && width > 0 )
{
double mapWidthHeightRatio = mapExtent.width() / mapExtent.height();
double imageWidthHeightRatio = ( double )width / ( double )height;

0 comments on commit e4d6bbf

Please sign in to comment.