1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-09 03:52:19 +02:00

Fixed double deletion issue with mParamNameMap

This commit is contained in:
Brian Fiete 2022-07-13 10:48:35 -04:00
parent 993053271b
commit 6cfd027362

View file

@ -3181,9 +3181,10 @@ void BfSystem::AddToCompositePartial(BfPassInstance* passInstance, BfTypeDef* co
}
else
{
newMethod = new BfMethodDef();
newMethod = new BfMethodDef();
*newMethod = *method;
}
method->mParamNameMap = NULL;
newMethod->mIdx = (int)typeDef->mMethods.size();
for (int paramIdx = 0; paramIdx < (int)newMethod->mParams.size(); paramIdx++)
{
@ -3408,6 +3409,7 @@ void BfSystem::CopyTypeDef(BfTypeDef* typeDef, BfTypeDef* fromTypeDef)
methodDef = new BfMethodDef();
*methodDef = *fromMethodDef;
}
fromMethodDef->mParamNameMap = NULL;
if (methodDef->mDeclaringType == fromTypeDef)
methodDef->mDeclaringType = typeDef;