From 4353599b7490f81405281689de7c4329aa7b2a95 Mon Sep 17 00:00:00 2001 From: Yukino Song Date: Tue, 3 Sep 2024 01:01:36 +0800 Subject: [PATCH] MISC --- src/confighttp.cpp | 2 +- src/platform/windows/publish.cpp | 8 ++++---- src/process.cpp | 10 +++++----- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/confighttp.cpp b/src/confighttp.cpp index e1f91963..29474148 100644 --- a/src/confighttp.cpp +++ b/src/confighttp.cpp @@ -658,7 +658,7 @@ namespace confighttp { // If user get a return, then the exit has failed. // This might not be thread safe but we're exiting anyways std::thread write_resp([response]{ - sleep(5000); + std::this_thread::sleep_for(5s); response->write(); }); write_resp.detach(); diff --git a/src/platform/windows/publish.cpp b/src/platform/windows/publish.cpp index 05208a9c..1bc9d2c6 100644 --- a/src/platform/windows/publish.cpp +++ b/src/platform/windows/publish.cpp @@ -176,21 +176,21 @@ namespace platf::publish { mdns_registration_t(): existing_instance(nullptr) { if (service(true, existing_instance)) { - BOOST_LOG(error) << "Unable to register Sunshine mDNS service"sv; + BOOST_LOG(error) << "Unable to register Apollo mDNS service"sv; return; } - BOOST_LOG(info) << "Registered Sunshine mDNS service"sv; + BOOST_LOG(info) << "Registered Apollo mDNS service"sv; } ~mdns_registration_t() override { if (existing_instance) { if (service(false, existing_instance)) { - BOOST_LOG(error) << "Unable to unregister Sunshine mDNS service"sv; + BOOST_LOG(error) << "Unable to unregister Apollo mDNS service"sv; return; } - BOOST_LOG(info) << "Unregistered Sunshine mDNS service"sv; + BOOST_LOG(info) << "Unregistered Apollo mDNS service"sv; } } diff --git a/src/process.cpp b/src/process.cpp index 8ff907b5..f3bda283 100644 --- a/src/process.cpp +++ b/src/process.cpp @@ -234,11 +234,11 @@ namespace proc { // Set primary display if needed if (shouldSetPrimary) { - VDISPLAY::setPrimaryDisplay( - (launch_session->virtual_display || _app.virtual_display_primary) - ? vdisplayName.c_str() - : prevPrimaryDisplayName.c_str() - ); + VDISPLAY::setPrimaryDisplay( + (launch_session->virtual_display || _app.virtual_display_primary) + ? vdisplayName.c_str() + : prevPrimaryDisplayName.c_str() + ); } // Set virtual_display to true when everything went fine