mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-22 10:49:05 +02:00
ELF loading potential out-of-bounds fix
This commit is contained in:
1 parent
b1b3b7c9d7
commit
42bdf3e19b
2 files changed
+4
-4
No files matched your search
@@ -1153,7 +1153,7 @@ static Module *__KernelLoadELFFromPtr(const u8 *ptr, size_t elfSize, u32 loadAdd
|
||||
module->Cleanup();
|
||||
kernelObjects.Destroy<Module>(module->GetUID());
|
||||
error = SCE_KERNEL_ERROR_UNSUPPORTED_PRX_TYPE;
|
||||
return 0;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// Open ELF reader
|
||||
@@ -1167,7 +1167,7 @@ static Module *__KernelLoadELFFromPtr(const u8 *ptr, size_t elfSize, u32 loadAdd
|
||||
module->Cleanup();
|
||||
kernelObjects.Destroy<Module>(module->GetUID());
|
||||
error = result;
|
||||
return 0;
|
||||
return nullptr;
|
||||
}
|
||||
module->memoryBlockAddr = reader.GetVaddr();
|
||||
module->memoryBlockSize = reader.GetTotalSize();
|
||||
|
||||
Reference in new issue
Block a user