[Pkg-owncloud-commits] [owncloud-client] 44/218: AccountSettings: Fix coverity warning
Sandro Knauß
hefee-guest at moszumanska.debian.org
Sat Oct 17 14:30:40 UTC 2015
This is an automated email from the git hooks/post-receive script.
hefee-guest pushed a commit to branch master
in repository owncloud-client.
commit f77ae28ed1a2299b773962c98173abf2ae697655
Author: Olivier Goffart <ogoffart at woboq.com>
Date: Tue Sep 1 11:39:55 2015 +0200
AccountSettings: Fix coverity warning
FolderMan::folder might return null
---
src/gui/accountsettings.cpp | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/gui/accountsettings.cpp b/src/gui/accountsettings.cpp
index c929932..de8baa3 100644
--- a/src/gui/accountsettings.cpp
+++ b/src/gui/accountsettings.cpp
@@ -286,9 +286,10 @@ void AccountSettings::slotResetCurrentFolder()
QMessageBox::Yes|QMessageBox::No );
if( ret == QMessageBox::Yes ) {
FolderMan *folderMan = FolderMan::instance();
- Folder *f = folderMan->folder(alias);
- f->slotTerminateSync();
- f->wipe();
+ if(Folder *f = folderMan->folder(alias)) {
+ f->slotTerminateSync();
+ f->wipe();
+ }
folderMan->slotScheduleAllFolders();
}
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud-client.git
More information about the Pkg-owncloud-commits
mailing list