summaryrefslogtreecommitdiff
path: root/platform/default
diff options
context:
space:
mode:
authorMike Morris <mikemorris@users.noreply.github.com>2016-10-12 22:32:55 -0400
committerMike Morris <mikemorris@users.noreply.github.com>2016-10-20 14:39:11 -0400
commit7bbd49c72c0daa7036a575a49f6cf13bf8a7020e (patch)
treeee3ba73132d35d789640f59c860fddf2a4a49ef8 /platform/default
parenta894870fb8f99632570ec1379fb55b287273fc58 (diff)
downloadqtlocation-mapboxgl-7bbd49c72c0daa7036a575a49f6cf13bf8a7020e.tar.gz
[core] extract weak_ptr mailbox->receive into Mailbox::maybeReceive
Diffstat (limited to 'platform/default')
-rw-r--r--platform/default/thread_pool.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/platform/default/thread_pool.cpp b/platform/default/thread_pool.cpp
index 7108312c58..b7e02db157 100644
--- a/platform/default/thread_pool.cpp
+++ b/platform/default/thread_pool.cpp
@@ -22,9 +22,7 @@ ThreadPool::ThreadPool(std::size_t count) {
queue.pop();
lock.unlock();
- if (auto locked = mailbox.lock()) {
- locked->receive();
- }
+ Mailbox::maybeReceive(mailbox);
}
});
}