mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-12-22 08:20:57 +01:00
pfs: Fix reading filenames past the buffer end
This commit is contained in:
parent
c708643972
commit
753bc3a448
1 changed files with 1 additions and 0 deletions
|
@ -47,6 +47,7 @@ PartitionFilesystem::PartitionFilesystem(VirtualFile file) {
|
|||
// Actually read in now...
|
||||
std::vector<u8> file_data = file->ReadBytes(metadata_size);
|
||||
const std::size_t total_size = file_data.size();
|
||||
file_data.push_back(0);
|
||||
|
||||
if (total_size != metadata_size) {
|
||||
status = Loader::ResultStatus::ErrorIncorrectPFSFileSize;
|
||||
|
|
Loading…
Reference in a new issue