SDL: Name the hotplug thread.
This commit is contained in:
1 parent
7cf6e7258c
commit
956f6cfbd2
1 file changed
+3
@@ -16,6 +16,7 @@
|
|||||||
#include "Common/Event.h"
|
#include "Common/Event.h"
|
||||||
#include "Common/Logging/Log.h"
|
#include "Common/Logging/Log.h"
|
||||||
#include "Common/ScopeGuard.h"
|
#include "Common/ScopeGuard.h"
|
||||||
|
#include "Common/Thread.h"
|
||||||
|
|
||||||
#include "InputCommon/ControllerInterface/ControllerInterface.h"
|
#include "InputCommon/ControllerInterface/ControllerInterface.h"
|
||||||
#include "InputCommon/ControllerInterface/SDL/SDLGamepad.h"
|
#include "InputCommon/ControllerInterface/SDL/SDLGamepad.h"
|
||||||
@@ -139,6 +140,8 @@ InputBackend::InputBackend(ControllerInterface* controller_interface)
|
|||||||
SDL_SetHint(SDL_HINT_JOYSTICK_HIDAPI_PS5_PLAYER_LED, "0");
|
SDL_SetHint(SDL_HINT_JOYSTICK_HIDAPI_PS5_PLAYER_LED, "0");
|
||||||
|
|
||||||
m_hotplug_thread = std::thread([this] {
|
m_hotplug_thread = std::thread([this] {
|
||||||
|
Common::SetCurrentThreadName("SDL Hotplug Thread");
|
||||||
|
|
||||||
Common::ScopeGuard quit_guard([] {
|
Common::ScopeGuard quit_guard([] {
|
||||||
// TODO: there seems to be some sort of memory leak with SDL, quit isn't freeing everything up
|
// TODO: there seems to be some sort of memory leak with SDL, quit isn't freeing everything up
|
||||||
SDL_Quit();
|
SDL_Quit();
|
||||||
|
|||||||
Reference in new issue
Block a user