Merge pull request #3534 from ReinUsesLisp/oob-time-zone

time_zone_content_manager: Fix out of bounds read
This commit is contained in:
bunnei 2020-03-18 19:12:05 -04:00 committed by GitHub
commit 76d6178e4a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,7 +53,7 @@ static std::vector<std::string> BuildLocationNameCache(Core::System& system) {
return {};
}
std::vector<char> raw_data(binary_list->GetSize());
std::vector<char> raw_data(binary_list->GetSize() + 1);
binary_list->ReadBytes<char>(raw_data.data(), binary_list->GetSize());
std::stringstream data_stream{raw_data.data()};