aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--jobs/basejob.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/jobs/basejob.cpp b/jobs/basejob.cpp
index 981b75b1..eb250723 100644
--- a/jobs/basejob.cpp
+++ b/jobs/basejob.cpp
@@ -235,8 +235,12 @@ void BaseJob::start(const ConnectionData* connData)
{
d->connection = connData;
beforeStart(connData);
- sendRequest();
- afterStart(connData, d->reply.data());
+ if (status().good())
+ sendRequest();
+ if (status().good())
+ afterStart(connData, d->reply.data());
+ if (!status().good())
+ QTimer::singleShot(0, this, &BaseJob::finishJob);
}
void BaseJob::sendRequest()