[XAM] Cap the number of dummy achievement details.

This commit is contained in:
gibbed 2021-05-08 08:57:51 -05:00 committed by Rick Gibbed
parent 1c78c9d75d
commit cf2037cdf6
1 changed files with 2 additions and 1 deletions

View File

@ -702,7 +702,8 @@ dword_result_t XamUserCreateAchievementEnumerator(dword_t title_id,
return result; return result;
} }
for (uint32_t i = 0; i < count; ++i) { uint32_t dummy_count = std::max(20u, uint32_t(count));
for (uint32_t i = 0; i < dummy_count; ++i) {
auto item = XStaticAchievementEnumerator::AchievementDetails{ auto item = XStaticAchievementEnumerator::AchievementDetails{
i, u"Dummy Text", u"Dummy Text", u"Dummy Text"}; i, u"Dummy Text", u"Dummy Text", u"Dummy Text"};
e->AppendItem(item); e->AppendItem(item);