[gnote] Properly report finish if failure
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Properly report finish if failure
- Date: Sat, 2 May 2020 19:10:28 +0000 (UTC)
commit 42a068690016b064ab5ed8d486f1355c416abdea
Author: Aurimas Černius <aurisc4 gmail com>
Date: Sat May 2 22:03:27 2020 +0300
Properly report finish if failure
src/synchronization/filesystemsyncserver.cpp | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
---
diff --git a/src/synchronization/filesystemsyncserver.cpp b/src/synchronization/filesystemsyncserver.cpp
index d4b52ee1..63a66422 100644
--- a/src/synchronization/filesystemsyncserver.cpp
+++ b/src/synchronization/filesystemsyncserver.cpp
@@ -112,17 +112,19 @@ void FileSystemSyncServer::upload_notes(const std::vector<Note::Ptr> & notes)
all_uploaded.signal();
}
notes_lock.unlock();
+ return;
}
}
catch (Glib::Exception & e) {
ERR_OUT(_("Failed to upload note: %s"), e.what().c_str());
- notes_lock.lock();
- ++failures;
- if(--total == 0) {
- all_uploaded.signal();
- }
- notes_lock.unlock();
}
+
+ notes_lock.lock();
+ ++failures;
+ if(--total == 0) {
+ all_uploaded.signal();
+ }
+ notes_lock.unlock();
});
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]