summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2020-10-16 05:58:18 +0200
committerbunnei <bunneidev@gmail.com>2020-10-17 06:16:56 +0200
commit363c644730198338140d9611b575ff22e14e1287 (patch)
treeaf9da56c8c61f3f46a46de29cde4294f09bc2c71 /src/core
parentMerge pull request #4790 from lioncash/input-common (diff)
downloadyuzu-363c644730198338140d9611b575ff22e14e1287.tar
yuzu-363c644730198338140d9611b575ff22e14e1287.tar.gz
yuzu-363c644730198338140d9611b575ff22e14e1287.tar.bz2
yuzu-363c644730198338140d9611b575ff22e14e1287.tar.lz
yuzu-363c644730198338140d9611b575ff22e14e1287.tar.xz
yuzu-363c644730198338140d9611b575ff22e14e1287.tar.zst
yuzu-363c644730198338140d9611b575ff22e14e1287.zip
Diffstat (limited to 'src/core')
-rw-r--r--src/core/hle/service/bcat/backend/boxcat.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/core/hle/service/bcat/backend/boxcat.cpp b/src/core/hle/service/bcat/backend/boxcat.cpp
index 589e288df..3b6f7498e 100644
--- a/src/core/hle/service/bcat/backend/boxcat.cpp
+++ b/src/core/hle/service/bcat/backend/boxcat.cpp
@@ -454,6 +454,16 @@ Boxcat::StatusResult Boxcat::GetStatus(std::optional<std::string>& global,
{std::string("Boxcat-Client-Type"), std::string(BOXCAT_CLIENT_TYPE)},
};
+ if (!client.is_valid()) {
+ LOG_ERROR(Service_BCAT, "Client is invalid, going offline!");
+ return StatusResult::Offline;
+ }
+
+ if (!client.is_socket_open()) {
+ LOG_ERROR(Service_BCAT, "Failed to open socket, going offline!");
+ return StatusResult::Offline;
+ }
+
const auto response = client.Get(BOXCAT_PATHNAME_EVENTS, headers);
if (response == nullptr)
return StatusResult::Offline;