mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-27 07:20:49 +00:00
Core: Correct a use after free.
This commit is contained in:
parent
1810692236
commit
c9f3878e9d
@ -392,8 +392,8 @@ bool UmdReplace(const Path &filepath, std::string &error) {
|
|||||||
FileLoader *loadedFile = ConstructFileLoader(filepath);
|
FileLoader *loadedFile = ConstructFileLoader(filepath);
|
||||||
|
|
||||||
if (!loadedFile->Exists()) {
|
if (!loadedFile->Exists()) {
|
||||||
delete loadedFile;
|
|
||||||
error = loadedFile->GetPath().ToVisualString() + " doesn't exist";
|
error = loadedFile->GetPath().ToVisualString() + " doesn't exist";
|
||||||
|
delete loadedFile;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
UpdateLoadedFile(loadedFile);
|
UpdateLoadedFile(loadedFile);
|
||||||
|
Loading…
Reference in New Issue
Block a user