diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-09-15 21:24:37 +0200 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-09-15 21:24:37 +0200 |
commit | 1deac558af4b1c9f04352ede7f8e172f11a70a6b (patch) | |
tree | 18d6e0441c4fb13f0c265ce6226d6e7179257fc8 /common/queryrunner.h | |
parent | 6d5be4fb7b8cbc450e2780905eaac9a18b486c5c (diff) | |
download | sink-1deac558af4b1c9f04352ede7f8e172f11a70a6b.tar.gz sink-1deac558af4b1c9f04352ede7f8e172f11a70a6b.zip |
Avoid crashing if the executing object is already gone when we go into
the continuation.
This happens if Kube is used to look at a folder that is currently being
freshly synchronized, so we continuously get new results.
Diffstat (limited to 'common/queryrunner.h')
-rw-r--r-- | common/queryrunner.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/common/queryrunner.h b/common/queryrunner.h index 155528e..439a990 100644 --- a/common/queryrunner.h +++ b/common/queryrunner.h | |||
@@ -74,8 +74,8 @@ private: | |||
74 | * A QueryRunner runs a query and updates the corresponding result set. | 74 | * A QueryRunner runs a query and updates the corresponding result set. |
75 | * | 75 | * |
76 | * The lifetime of the QueryRunner is defined by the resut set (otherwise it's doing useless work), | 76 | * The lifetime of the QueryRunner is defined by the resut set (otherwise it's doing useless work), |
77 | * and by how long a result set must be updated. If the query is one off the runner dies after the execution, | 77 | * and by how long a result set must be updated. If the query is a one off, the runner dies after the execution, |
78 | * otherwise it lives on the react to changes and updates the corresponding result set. | 78 | * otherwise it lives on to react to changes, and updates the corresponding result set. |
79 | * | 79 | * |
80 | * QueryRunner has to keep ResourceAccess alive in order to keep getting updates. | 80 | * QueryRunner has to keep ResourceAccess alive in order to keep getting updates. |
81 | */ | 81 | */ |
@@ -101,4 +101,5 @@ private: | |||
101 | ResultTransformation mResultTransformation; | 101 | ResultTransformation mResultTransformation; |
102 | QHash<QByteArray, qint64> mOffset; | 102 | QHash<QByteArray, qint64> mOffset; |
103 | int mBatchSize; | 103 | int mBatchSize; |
104 | QObject guard; | ||
104 | }; | 105 | }; |