aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/thread/TaskRunner.cpp
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2023-12-28 06:32:49 +0000
committersaturneric <[email protected]>2023-12-28 06:32:49 +0000
commit300e55bf5bddc393de050c2ca9a0356fce9a8a9d (patch)
tree8332e6b50158718ad98c954302951668a57712a8 /src/core/thread/TaskRunner.cpp
parentfeat: avoid reading entire file to memory (diff)
downloadGpgFrontend-300e55bf5bddc393de050c2ca9a0356fce9a8a9d.tar.gz
GpgFrontend-300e55bf5bddc393de050c2ca9a0356fce9a8a9d.zip
feat: add simple archiving functions for encrypt and decrypt
Diffstat (limited to 'src/core/thread/TaskRunner.cpp')
-rw-r--r--src/core/thread/TaskRunner.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/core/thread/TaskRunner.cpp b/src/core/thread/TaskRunner.cpp
index a4a97b38..6d5edd93 100644
--- a/src/core/thread/TaskRunner.cpp
+++ b/src/core/thread/TaskRunner.cpp
@@ -39,10 +39,7 @@ namespace GpgFrontend::Thread {
class TaskRunner::Impl : public QThread {
public:
- Impl() {
- SPDLOG_TRACE("task runner created, thread id: {}",
- QThread::currentThread()->currentThreadId());
- }
+ Impl() : QThread(nullptr) {}
void PostTask(Task* task) {
if (task == nullptr) {
@@ -53,7 +50,8 @@ class TaskRunner::Impl : public QThread {
task->setParent(nullptr);
task->moveToThread(this);
- SPDLOG_TRACE("runner starts task: {}", task->GetFullID());
+ SPDLOG_TRACE("runner starts task: {} at thread: {}", task->GetFullID(),
+ this->currentThreadId());
task->SafelyRun();
}