Set '_abortRequested' properly within the propagator so the error is not displayed...
authoralex-z <blackslayer4@gmail.com>
Tue, 6 Sep 2022 14:15:53 +0000 (17:15 +0300)
committerallexzander <blackslayer4@gmail.com>
Wed, 7 Sep 2022 10:35:42 +0000 (13:35 +0300)
Signed-off-by: alex-z <blackslayer4@gmail.com>
src/libsync/owncloudpropagator.cpp
src/libsync/owncloudpropagator.h

index 245a8e8d6026d2eb868bb071b7234303a16b24b8..0591483cf2d565f9d1eebc85c1fbfb0ab94bf1ae 100644 (file)
@@ -482,6 +482,8 @@ void OwncloudPropagator::start(SyncFileItemVector &&items)
 {
     Q_ASSERT(std::is_sorted(items.begin(), items.end()));
 
+    _abortRequested = false;
+
     /* This builds all the jobs needed for the propagation.
      * Each directory is a PropagateDirectory job, which contains the files in it.
      * In order to do that we loop over the items. (which are sorted by destination)
index 79d017e8283897a46a9016cb2d4fef9b9e7c57a1..951a63d5a80f52fab4600c5e80f41e83ce39811b 100644 (file)
@@ -538,6 +538,8 @@ public:
     {
         if (_abortRequested)
             return;
+
+        _abortRequested = true;
         if (_rootJob) {
             // Connect to abortFinished  which signals that abort has been asynchronously finished
             connect(_rootJob.data(), &PropagateDirectory::abortFinished, this, &OwncloudPropagator::emitFinished);
@@ -633,6 +635,7 @@ private slots:
     {
         if (!_finishedEmited)
             emit finished(status == SyncFileItem::Success);
+        _abortRequested = false;
         _finishedEmited = true;
     }