refactor: use std::string for thread names

This commit is contained in:
stickies-v
2022-08-31 16:30:35 +01:00
parent 29d540b7ad
commit 97f5b20c12
5 changed files with 10 additions and 7 deletions

View File

@@ -10,10 +10,12 @@
#include <exception>
#include <functional>
#include <string>
#include <utility>
void util::TraceThread(const char* thread_name, std::function<void()> thread_func)
void util::TraceThread(std::string_view thread_name, std::function<void()> thread_func)
{
util::ThreadRename(thread_name);
util::ThreadRename(std::string{thread_name});
try {
LogPrintf("%s thread start\n", thread_name);
thread_func();