Bug report #1083

OGR SQL result set leaks due to incorrect call of deallocator

Added by Mateusz Loskot - over 13 years ago. Updated over 13 years ago.

Status:Closed
Priority:Low
Assignee:nobody -
Category:-
Affected QGIS version: Regression?:No
Operating System:Linux Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:11143

Description

In file [source:trunk/qgis/src/providers/ogr/[email protected]#L1290 qgsogrprovider.cpp], line 1290, invalid call of function OGR_DS_ReleaseResultSet causes memory leak in GDAL/OGR.

The function is called with parameters in incorrect order:

OGR_DS_ReleaseResultSet(l, ogrDataSource);

but it should read

OGR_DS_ReleaseResultSet(ogrDataSource, l);

In other words, datasource handle goes first, then layer handle (see OGR_DS_ReleaseResultSet prototype).

Associated revisions

Revision 1ef1e9c0
Added by Jürgen Fischer over 13 years ago

fix leaks calling OGR_DS_ExecuteSQL (fixes #1083)

git-svn-id: http://svn.osgeo.org/qgis/trunk/[email protected] c8812cc2-4d05-0410-92ff-de0c093fc19c

Revision f0386c65
Added by Jürgen Fischer over 13 years ago

fix leaks calling OGR_DS_ExecuteSQL (fixes #1083)

git-svn-id: http://svn.osgeo.org/qgis/[email protected] c8812cc2-4d05-0410-92ff-de0c093fc19c

History

#1 Updated by Jürgen Fischer over 13 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

fixed in

Also available in: Atom PDF