Fixed: Correct memory leak found by cppcheck
parent
4619625b84
commit
67cb86d166
|
@ -482,8 +482,9 @@ aiReturn aiMaterial::AddBinaryProperty (const void* pInput,
|
||||||
|
|
||||||
aiMaterialProperty** ppTemp;
|
aiMaterialProperty** ppTemp;
|
||||||
try {
|
try {
|
||||||
ppTemp = new aiMaterialProperty*[mNumAllocated];
|
ppTemp = new aiMaterialProperty*[mNumAllocated];
|
||||||
} catch (std::bad_alloc&) {
|
} catch (std::bad_alloc&) {
|
||||||
|
delete pcNew;
|
||||||
return AI_OUTOFMEMORY;
|
return AI_OUTOFMEMORY;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue