mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
refactor: rename miniaudio thread (#5538)
This commit is contained in:
parent
74d65a345d
commit
2b45b2e0a9
|
@ -61,6 +61,7 @@
|
|||
- Dev: Refactored 7TV/BTTV definitions out of `TwitchIrcServer` into `Application`. (#5532)
|
||||
- Dev: Refactored code that's responsible for deleting old update files. (#5535)
|
||||
- Dev: Cleanly exit on shutdown. (#5537)
|
||||
- Dev: Renamed miniaudio backend thread name. (#5538)
|
||||
- Dev: Refactored a few `#define`s into `const(expr)` and cleaned includes. (#5527)
|
||||
- Dev: Prepared for Qt 6.8 by addressing some deprecations. (#5529)
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
#include "singletons/Paths.hpp"
|
||||
#include "singletons/Settings.hpp"
|
||||
#include "singletons/WindowManager.hpp"
|
||||
#include "util/RenameThread.hpp"
|
||||
#include "widgets/Window.hpp"
|
||||
|
||||
#include <boost/asio/executor_work_guard.hpp>
|
||||
|
@ -193,6 +194,7 @@ MiniaudioBackend::MiniaudioBackend()
|
|||
this->audioThread = std::make_unique<std::thread>([this] {
|
||||
this->ioContext.run();
|
||||
});
|
||||
renameThread(*this->audioThread, "C2Miniaudio");
|
||||
}
|
||||
|
||||
MiniaudioBackend::~MiniaudioBackend()
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
namespace chatterino {
|
||||
|
||||
template <typename T>
|
||||
void renameThread(T &&thread, const QString &threadName)
|
||||
void renameThread(T &thread, const QString &threadName)
|
||||
{
|
||||
#ifdef Q_OS_LINUX
|
||||
pthread_setname_np(thread.native_handle(), threadName.toLocal8Bit());
|
||||
|
|
Loading…
Reference in a new issue