Skip to content

Commit 343bc8a

Browse files
committed
Fix expressions leaking internal data
(cherry-picked from 15dcb6)
1 parent 7ee5d8a commit 343bc8a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/core/qgsexpression.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3697,6 +3697,11 @@ QgsExpression::QgsExpression( const QgsExpression& other )
36973697

36983698
QgsExpression& QgsExpression::operator=( const QgsExpression & other )
36993699
{
3700+
if ( !d->ref.deref() )
3701+
{
3702+
delete d;
3703+
}
3704+
37003705
d = other.d;
37013706
d->ref.ref();
37023707
return *this;

0 commit comments

Comments
 (0)