Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
[GRASS] close vector map if no more users, fixes #14668
- Loading branch information
Showing
with
4 additions
and
3 deletions.
-
+4
−3
src/providers/grass/qgsgrassvectormap.cpp
|
@@ -76,6 +76,7 @@ int QgsGrassVectorMap::userCount() const |
|
|
{ |
|
|
count += layer->userCount(); |
|
|
} |
|
|
QgsDebugMsg( QString( "count = %1" ).arg( count ) ); |
|
|
return count; |
|
|
} |
|
|
|
|
@@ -443,9 +444,9 @@ void QgsGrassVectorMap::closeLayer( QgsGrassVectorMapLayer * layer ) |
|
|
QgsDebugMsg( QString( "%1 map users" ).arg( userCount() ) ); |
|
|
if ( userCount() == 0 ) |
|
|
{ |
|
|
// TODO: attention about dead lock, probably move to QgsGrassVectorMapStore |
|
|
//QgsDebugMsg( "No more map users -> close" ); |
|
|
//close(); |
|
|
QgsDebugMsg( "No more map users -> close" ); |
|
|
// Once was probably causing dead lock; move to QgsGrassVectorMapStore? |
|
|
close(); |
|
|
} |
|
|
|
|
|
QgsDebugMsg( "layer closed" ); |
|
|