diff options
| author | cirakg <cirakg@cirakg.xyz> | 2026-11-02 23:55:44 +0100 |
|---|---|---|
| committer | cirakg <cirakg@cirakg.xyz> | 2026-11-02 23:55:44 +0100 |
| commit | a931609f31672f782d2817f5764d65c00dea4dad (patch) | |
| tree | 3cb5bd166d1a54a76969afd61c1db835c9cb293d /src/input_common | |
| parent | 3e10d48548a285172ea7cb1f94c58783e1d97754 (diff) | |
| parent | 8362c44ff835d7be73d2adad9ce3e2d4467a6aeb (diff) | |
Merge branch 'nx2' into ldn/room-handshake
Diffstat (limited to 'src/input_common')
| -rw-r--r-- | src/input_common/drivers/udp_client.cpp | 4 | ||||
| -rw-r--r-- | src/input_common/drivers/udp_client.h | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/input_common/drivers/udp_client.cpp b/src/input_common/drivers/udp_client.cpp index 620e0cf630..a7840db32f 100644 --- a/src/input_common/drivers/udp_client.cpp +++ b/src/input_common/drivers/udp_client.cpp @@ -603,7 +603,7 @@ CalibrationConfigurationJob::CalibrationConfigurationJob( const std::string& host, u16 port, std::function<void(Status)> status_callback, std::function<void(u16, u16, u16, u16)> data_callback) { - std::thread([=, this] { + worker = std::jthread([=, this] { u16 min_x{UINT16_MAX}; u16 min_y{UINT16_MAX}; u16 max_x{}; @@ -647,7 +647,7 @@ CalibrationConfigurationJob::CalibrationConfigurationJob( complete_event.Wait(); socket.Stop(); worker_thread.join(); - }).detach(); + }); } CalibrationConfigurationJob::~CalibrationConfigurationJob() { diff --git a/src/input_common/drivers/udp_client.h b/src/input_common/drivers/udp_client.h index cea9f579ac..eac3df07aa 100644 --- a/src/input_common/drivers/udp_client.h +++ b/src/input_common/drivers/udp_client.h @@ -183,6 +183,7 @@ public: private: Common::Event complete_event; + std::jthread worker; }; void TestCommunication(const std::string& host, u16 port, |
