From 77682aabd3a8c4dbda3dd20421a5dea16b6ef86d Mon Sep 17 00:00:00 2001 From: lat9nq <22451773+lat9nq@users.noreply.github.com> Date: Sun, 17 Sep 2023 15:23:57 -0400 Subject: mii_types: Remove null terminator check This is an OoB array access, causing a crash on at least the Linux Flatpak releases. Co-authored-by: german77 --- src/core/hle/service/mii/mii_types.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/core/hle') diff --git a/src/core/hle/service/mii/mii_types.h b/src/core/hle/service/mii/mii_types.h index 95476f745..611ff4f81 100644 --- a/src/core/hle/service/mii/mii_types.h +++ b/src/core/hle/service/mii/mii_types.h @@ -606,15 +606,12 @@ struct Nickname { static constexpr std::size_t MaxNameSize = 10; std::array data; - // Checks for null, non-zero terminated or dirty strings + // Checks for null or dirty strings bool IsValid() const { if (data[0] == 0) { return false; } - if (data[MaxNameSize] != 0) { - return false; - } std::size_t index = 1; while (data[index] != 0) { index++; -- cgit v1.2.3