BSIM 3.3.0 plug memory leak during remcirc
This commit is contained in:
parent
9e8219da67
commit
d6946705f8
|
|
@ -35,7 +35,10 @@ BSIM3destroy(
|
|||
FREE(pParamOld);
|
||||
pParam = NULL;
|
||||
/** end of extra code **/
|
||||
if(oldmod) FREE(oldmod);
|
||||
if(oldmod) {
|
||||
FREE(oldmod->BSIM3version);
|
||||
FREE(oldmod);
|
||||
}
|
||||
oldmod = mod;
|
||||
prev = NULL;
|
||||
for (here = mod->BSIM3instances; here; here = here->BSIM3nextInstance) {
|
||||
|
|
@ -49,6 +52,8 @@ BSIM3destroy(
|
|||
/* free just once for all models */
|
||||
FREE(oldmod->BSIM3InstanceArray);
|
||||
#endif
|
||||
/* oldmod->BSIM3modName to be freed in INPtabEnd() */
|
||||
FREE(oldmod->BSIM3version);
|
||||
FREE(oldmod);
|
||||
}
|
||||
*model = NULL;
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ BSIM3instance **InstArray;
|
|||
printf("Warning: acnqsMod has been set to its default value: 0.\n");
|
||||
}
|
||||
if (!model->BSIM3versionGiven)
|
||||
model->BSIM3version = "3.3.0";
|
||||
model->BSIM3version = copy("3.3.0");
|
||||
if (!model->BSIM3toxGiven)
|
||||
model->BSIM3tox = 150.0e-10;
|
||||
model->BSIM3cox = 3.453133e-11 / model->BSIM3tox;
|
||||
|
|
|
|||
Loading…
Reference in New Issue