Skip to content

Commit

Permalink
Merge pull request #1520 from Karry/async-worker-name
Browse files Browse the repository at this point in the history
set name of async-worker thread
  • Loading branch information
Framstag authored Nov 1, 2023
2 parents d82b2ae + 737e08c commit 62f682a
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions libosmscout/src/osmscout/async/AsyncWorker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,17 @@

#include <osmscout/async/AsyncWorker.h>

#include <osmscout/async/Thread.h>

namespace osmscout {

AsyncWorker::AsyncWorker(const std::string&):
AsyncWorker::AsyncWorker(const std::string &name):
thread(&AsyncWorker::Loop,this)
{

Async<int>([name](Breaker &) -> int {
SetThreadName(name);
return 0;
});
}

AsyncWorker::~AsyncWorker()
Expand Down

0 comments on commit 62f682a

Please sign in to comment.