AccountSetting: Fix Small Memoy leak
authorOlivier Goffart <ogoffart@woboq.com>
Sun, 16 Sep 2018 19:52:50 +0000 (21:52 +0200)
committerKevin Ottens <kevin.ottens@nextcloud.com>
Tue, 15 Dec 2020 09:58:06 +0000 (10:58 +0100)
src/gui/accountsettings.cpp

index e2676b8125d43fa3e3bc0babb5a0b3d3e9e6ffac..ae0139ab919c725cdae09f7208bbe57378a7392b 100644 (file)
@@ -481,6 +481,7 @@ void AccountSettings::slotAddFolder()
     folderMan->setSyncEnabled(false); // do not start more syncs.
 
     auto *folderWizard = new FolderWizard(_accountState->account(), this);
+    folderWizard->setAttribute(Qt::WA_DeleteOnClose);
 
     connect(folderWizard, &QDialog::accepted, this, &AccountSettings::slotFolderWizardAccepted);
     connect(folderWizard, &QDialog::rejected, this, &AccountSettings::slotFolderWizardRejected);