Skip to content
Permalink
Browse files
Added a check for value out of bounds in QgsOgrProvider
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5658 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Aug 2, 2006
1 parent e200ec8 commit ec7742e3c32a502588ebad8720ab03dd710422ff
Showing with 3 additions and 2 deletions.
  1. +3 −2 src/providers/ogr/qgsogrprovider.cpp
@@ -833,11 +833,12 @@ QString QgsOgrProvider::minValue(int position)

QString QgsOgrProvider::maxValue(int position)
{
if(position>=fieldCount())
if(position>=fieldCount() || position < 0)
{
#ifdef QGISDEBUG
QgsLogger::warning("Warning: access requested to invalid position in QgsOgrProvider::maxValue(..)");
#endif
#endif
return "";
}
if(minmaxcachedirty)
{

0 comments on commit ec7742e

Please sign in to comment.