Fix issue with memory validation

This commit is contained in:
Zion Nimchuk 2018-10-09 21:59:33 -07:00 committed by Ivan
parent 3a7f5b970f
commit fa134337d9

View File

@ -2,6 +2,7 @@
#include "Emu/System.h"
#include "TRP.h"
#include "Crypto/sha1.h"
#include "Utilities/StrUtil.h"
TRPLoader::TRPLoader(const fs::file& f)
: trp_f(f)
@ -141,11 +142,11 @@ void TRPLoader::RemoveEntry(const char *filename)
void TRPLoader::RenameEntry(const char *oldname, const char *newname)
{
for (const TRPEntry& entry : m_entries)
for (TRPEntry& entry : m_entries)
{
if (!strcmp(entry.name, oldname))
{
memcpy((void*)entry.name, newname, 32);
strcpy_trunc(entry.name, newname);
}
}
}