Skip to content

Commit

Permalink
Fix potential crash on exit
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Nov 1, 2018
1 parent dae9376 commit 132688e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/app/qgisapp.cpp
Expand Up @@ -1559,6 +1559,14 @@ QgisApp::~QgisApp()
delete canvas;
}

// these may have references to map layers which need to be cleaned up
delete mBrowserWidget;
mBrowserWidget = nullptr;
delete mBrowserWidget2;
mBrowserWidget2 = nullptr;
delete mBrowserModel;
mBrowserModel = nullptr;

QgsGui::instance()->nativePlatformInterface()->cleanup();

// This function *MUST* be the last one called, as it destroys in
Expand Down

0 comments on commit 132688e

Please sign in to comment.