forked from qt-creator/qt-creator
Don't leak BeautifierPluginPrivate on shutdown
Properly delete QtcProcess used for version on shutdown. Change-Id: I325a267ba5bb28a82158d9c50802955804713be0 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -133,6 +133,13 @@ void BeautifierPlugin::extensionsInitialized()
|
||||
dd = new BeautifierPluginPrivate;
|
||||
}
|
||||
|
||||
ExtensionSystem::IPlugin::ShutdownFlag BeautifierPlugin::aboutToShutdown()
|
||||
{
|
||||
delete dd;
|
||||
dd = nullptr;
|
||||
return SynchronousShutdown;
|
||||
}
|
||||
|
||||
BeautifierPluginPrivate::BeautifierPluginPrivate()
|
||||
{
|
||||
updateActions();
|
||||
|
@@ -49,6 +49,7 @@ public:
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void extensionsInitialized() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
Reference in New Issue
Block a user