summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFearlessTobi <thm.frey@gmail.com>2022-08-27 04:49:10 +0200
committerFearlessTobi <thm.frey@gmail.com>2022-08-27 04:49:10 +0200
commit6791301d9a2fa8ddfe0de0d059763c701b830f94 (patch)
tree7885c5c238609834c58fd6ff36126c2bd9eb96f1
parentyuzu/chat_room: Make font size bigger (diff)
downloadyuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.tar
yuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.tar.gz
yuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.tar.bz2
yuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.tar.lz
yuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.tar.xz
yuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.tar.zst
yuzu-6791301d9a2fa8ddfe0de0d059763c701b830f94.zip
-rw-r--r--src/core/hle/service/ldn/ldn_types.h17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/core/hle/service/ldn/ldn_types.h b/src/core/hle/service/ldn/ldn_types.h
index 0c07a7397..0af653164 100644
--- a/src/core/hle/service/ldn/ldn_types.h
+++ b/src/core/hle/service/ldn/ldn_types.h
@@ -113,7 +113,7 @@ enum class LinkLevel : s8 {
Bad,
Low,
Good,
- Excelent,
+ Excellent,
};
struct NodeLatestUpdate {
@@ -148,9 +148,24 @@ struct Ssid {
u8 length;
std::array<char, SsidLengthMax + 1> raw;
+ Ssid() {
+ length = 0;
+ std::memset(raw.data(), 0, raw.size());
+ }
+
+ Ssid(std::string data) {
+ length = static_cast<u8>(std::min(data.size(), SsidLengthMax));
+ std::memcpy(raw.data(), data.data(), length);
+ raw[length] = 0;
+ }
+
std::string GetStringValue() const {
return std::string(raw.data(), length);
}
+
+ bool operator==(const Ssid& b) const {
+ return (length == b.length) && (std::memcmp(raw.data(), b.raw.data(), length) == 0);
+ }
};
static_assert(sizeof(Ssid) == 0x22, "Ssid is an invalid size");