Skip to content
Permalink
Browse files
fix leaks calling OGR_DS_ExecuteSQL (fixes #1083)
git-svn-id: http://svn.osgeo.org/qgis/trunk@8420 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed May 10, 2008
1 parent 2429630 commit f0386c65487b912126f819b65104ad0dcd8258f8
Showing with 5 additions and 5 deletions.
  1. +5 −5 src/providers/ogr/qgsogrprovider.cpp
@@ -1287,7 +1287,7 @@ void QgsOgrProvider::getUniqueValues(int index, QStringList &uniqueValues)
OGR_F_Destroy(f);
}

OGR_DS_ReleaseResultSet(l, ogrDataSource);
OGR_DS_ReleaseResultSet(ogrDataSource, l);
}


@@ -1309,7 +1309,7 @@ QVariant QgsOgrProvider::minValue(int index)
OGRFeatureH f = OGR_L_GetNextFeature(l);
if(f==0)
{
OGR_DS_ReleaseResultSet(l, ogrDataSource);
OGR_DS_ReleaseResultSet(ogrDataSource, l);
return QVariant();
}

@@ -1327,7 +1327,7 @@ QVariant QgsOgrProvider::minValue(int index)
default: assert(NULL && "unsupported field type");
}

OGR_DS_ReleaseResultSet(l, ogrDataSource);
OGR_DS_ReleaseResultSet(ogrDataSource, l);

return value;
}
@@ -1348,7 +1348,7 @@ QVariant QgsOgrProvider::maxValue(int index)
OGRFeatureH f = OGR_L_GetNextFeature(l);
if(f==0)
{
OGR_DS_ReleaseResultSet(l, ogrDataSource);
OGR_DS_ReleaseResultSet(ogrDataSource, l);
return QVariant();
}

@@ -1366,7 +1366,7 @@ QVariant QgsOgrProvider::maxValue(int index)
default: assert(NULL && "unsupported field type");
}

OGR_DS_ReleaseResultSet(l, ogrDataSource);
OGR_DS_ReleaseResultSet(ogrDataSource, l);

return value;
}

0 comments on commit f0386c6

Please sign in to comment.