Don't leak block on allocation failure.

This commit is contained in:
Unknown W. Brackets 2013-02-28 00:19:07 -08:00
parent eab7777ec3
commit 1e3f5477c3
2 changed files with 2 additions and 1 deletions

View File

@ -506,6 +506,7 @@ int sceKernelAllocPartitionMemory(int partition, const char *name, int type, u32
PartitionMemoryBlock *block = new PartitionMemoryBlock(&userMemory, name, size, (MemblockType)type, addr);
if (!block->IsValid())
{
delete block;
ERROR_LOG(HLE, "ARGH! sceKernelAllocPartitionMemory failed");
return SCE_KERNEL_ERROR_MEMBLOCK_ALLOC_FAILED;
}

@ -1 +1 @@
Subproject commit 7211f79d7df7dc8efc59d3d568a2cbd41772136c
Subproject commit a9c949b87dc69d4d6cde854b73455a170a2aaff4