mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-22 00:06:12 -05:00
fix(Snapping): avoid memory leaks of point locator
This commit is contained in:
parent
7fd1c662eb
commit
15dca8dd7f
@ -45,7 +45,7 @@ QgsPointLocator *QgsSnappingUtils::locatorForLayer( QgsVectorLayer *vl )
|
||||
connect( vlpl, &QgsPointLocator::initFinished, this, &QgsSnappingUtils::onInitFinished );
|
||||
connect( vl, &QObject::destroyed, this, [this, vl]()
|
||||
{
|
||||
mLocators.remove( vl );
|
||||
delete mLocators.take( vl );
|
||||
} );
|
||||
|
||||
mLocators.insert( vl, vlpl );
|
||||
|
Loading…
x
Reference in New Issue
Block a user