[Pkg-owncloud-commits] [owncloud-client] 28/33: Another fix for the reconnect-logic
Sandro Knauß
hefee-guest at moszumanska.debian.org
Thu Feb 27 19:44:25 UTC 2014
This is an automated email from the git hooks/post-receive script.
hefee-guest pushed a commit to branch upstream
in repository owncloud-client.
commit 05a1f7b1bb65bf041da0ae6d75ea1006911d15d6
Author: Daniel Molkentin <danimo at owncloud.com>
Date: Wed Feb 26 11:26:50 2014 +0100
Another fix for the reconnect-logic
---
src/mirall/quotainfo.cpp | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/src/mirall/quotainfo.cpp b/src/mirall/quotainfo.cpp
index 70dc3b1..46cf4dd 100644
--- a/src/mirall/quotainfo.cpp
+++ b/src/mirall/quotainfo.cpp
@@ -65,29 +65,29 @@ void QuotaInfo::slotRequestFailed()
if (!_account.isNull() && _account->state() == Account::Connected) {
_account->setState(Account::Disconnected);
}
+
+ _lastQuotaTotalBytes = 0;
+ _lastQuotaUsedBytes = 0;
+ _jobRestartTimer->start(failIntervalT);
+
_jobRestartTimer->start(failIntervalT);
}
void QuotaInfo::slotCheckQuota()
{
- if (!_account.isNull() && _account->credentials() && _account->credentials()->ready()
- && _account->state() == Account::Connected) {
- if(_account->state() == Account::Disconnected) {
- _account->setState(Account::Connected);
- }
+ if (!_account.isNull() && _account->credentials() && _account->credentials()->ready()) {
CheckQuotaJob *job = new CheckQuotaJob(_account, "/", this);
connect(job, SIGNAL(quotaRetrieved(qint64,qint64)), SLOT(slotUpdateLastQuota(qint64,qint64)));
connect(job, SIGNAL(networkError(QNetworkReply*)), SLOT(slotRequestFailed()));
job->start();
- } else {
- _lastQuotaTotalBytes = 0;
- _lastQuotaUsedBytes = 0;
- _jobRestartTimer->start(failIntervalT);
}
}
void QuotaInfo::slotUpdateLastQuota(qint64 total, qint64 used)
{
+ if(_account->state() == Account::Disconnected) {
+ _account->setState(Account::Connected);
+ }
_lastQuotaTotalBytes = total;
_lastQuotaUsedBytes = used;
emit quotaUpdated(total, used);
--
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