summaryrefslogtreecommitdiff
path: root/src/location/labs/qmaprouteobject.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/location/labs/qmaprouteobject.cpp')
-rw-r--r--src/location/labs/qmaprouteobject.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/location/labs/qmaprouteobject.cpp b/src/location/labs/qmaprouteobject.cpp
index 7e36322c..c3365d30 100644
--- a/src/location/labs/qmaprouteobject.cpp
+++ b/src/location/labs/qmaprouteobject.cpp
@@ -170,7 +170,8 @@ void QMapRouteObject::setMap(QGeoMap *map)
QGeoMapObject::setMap(map); // This is where the specialized pimpl gets created and injected
if (!map) {
- // Map was set, now it has ben re-set to NULL
+ // Map was set, now it has ben re-set to NULL, but not inside d_ptr.
+ // so m_map inside d_ptr can still be used to remove itself, inside the destructor.
d_ptr = new QMapRouteObjectPrivate(*d);
// Old pimpl deleted implicitly by QExplicitlySharedDataPointer
}