BSIM 4.7.0 plug memory leak during remcirc
This commit is contained in:
parent
d38d907fbc
commit
abbda029e1
|
|
@ -37,7 +37,10 @@ BSIM4destroy(
|
|||
FREE(pParamOld);
|
||||
pParam = NULL;
|
||||
/** end of extra code **/
|
||||
if(oldmod) FREE(oldmod);
|
||||
if(oldmod) {
|
||||
FREE(oldmod->BSIM4version);
|
||||
FREE(oldmod);
|
||||
}
|
||||
oldmod = mod;
|
||||
prev = (BSIM4instance *)NULL;
|
||||
for (here = mod->BSIM4instances; here; here = here->BSIM4nextInstance) {
|
||||
|
|
@ -51,6 +54,8 @@ BSIM4destroy(
|
|||
/* free just once for all models */
|
||||
FREE(oldmod->BSIM4InstanceArray);
|
||||
#endif
|
||||
/* oldmod->BSIM4modName to be freed in INPtabEnd() */
|
||||
FREE(oldmod->BSIM4version);
|
||||
FREE(oldmod);
|
||||
}
|
||||
*model = NULL;
|
||||
|
|
|
|||
|
|
@ -208,7 +208,7 @@ BSIM4instance **InstArray;
|
|||
}
|
||||
|
||||
if (!model->BSIM4versionGiven)
|
||||
model->BSIM4version = "4.7.0";
|
||||
model->BSIM4version = copy("4.7.0");
|
||||
if (!model->BSIM4toxrefGiven)
|
||||
model->BSIM4toxref = 30.0e-10;
|
||||
if (!model->BSIM4eotGiven)
|
||||
|
|
|
|||
Loading…
Reference in New Issue