Index: ../trunk-jpl/src/c/classes/Elements/Tria.cpp =================================================================== --- ../trunk-jpl/src/c/classes/Elements/Tria.cpp (revision 21875) +++ ../trunk-jpl/src/c/classes/Elements/Tria.cpp (revision 21876) @@ -2679,6 +2679,7 @@ /*}}}*/ void Tria::ResetHooks(){/*{{{*/ + if(this->nodes) xDelete(this->nodes); this->nodes=NULL; this->vertices=NULL; this->material=NULL; Index: ../trunk-jpl/src/c/classes/Elements/Penta.cpp =================================================================== --- ../trunk-jpl/src/c/classes/Elements/Penta.cpp (revision 21875) +++ ../trunk-jpl/src/c/classes/Elements/Penta.cpp (revision 21876) @@ -171,7 +171,7 @@ this->inputs->AddInput(new PentaInput(input_enum,values,interpolation_enum)); } /*}}}*/ -void Penta::BasalNodeIndices(int* pnumindices,int** pindices,int finiteelement){/*{{{*/ +void Penta::BasalNodeIndices(int* pnumindices,int** pindices,int finiteelement){/*{{{*/ PentaRef::BasalNodeIndices(pnumindices,pindices,finiteelement); @@ -2212,6 +2212,7 @@ /*}}}*/ void Penta::ResetHooks(){/*{{{*/ + if(this->nodes) xDelete(this->nodes); this->nodes=NULL; this->vertices=NULL; this->material=NULL; Index: ../trunk-jpl/src/c/classes/Elements/Tetra.cpp =================================================================== --- ../trunk-jpl/src/c/classes/Elements/Tetra.cpp (revision 21875) +++ ../trunk-jpl/src/c/classes/Elements/Tetra.cpp (revision 21876) @@ -807,6 +807,7 @@ /*}}}*/ void Tetra::ResetHooks(){/*{{{*/ + if(this->nodes) xDelete(this->nodes); this->nodes=NULL; this->vertices=NULL; this->material=NULL; Index: ../trunk-jpl/src/c/classes/Dakota/IssmParallelDirectApplicInterface.cpp =================================================================== --- ../trunk-jpl/src/c/classes/Dakota/IssmParallelDirectApplicInterface.cpp (revision 21875) +++ ../trunk-jpl/src/c/classes/Dakota/IssmParallelDirectApplicInterface.cpp (revision 21876) @@ -48,7 +48,8 @@ FemModel* femmodel; - char **responses_descriptors = NULL; //these are our! there are only numresponsedescriptors of them, not d_numresponses!!! + char **responses_descriptors = NULL; //these are ours! there are only numresponsedescriptors of them, not d_numresponses!!! + char *response_descriptor = NULL; int numresponsedescriptors; int solution_type; bool control_analysis = false; @@ -127,6 +128,11 @@ xDelete(variable_descriptor); } xDelete(variable_descriptors); + for(i=0;i(response_descriptor); + } + if(responses_descriptors) xDelete(responses_descriptors); xDelete(responses); delete femmodel; Index: ../trunk-jpl/src/c/main/issm_dakota.cpp =================================================================== --- ../trunk-jpl/src/c/main/issm_dakota.cpp (revision 21875) +++ ../trunk-jpl/src/c/main/issm_dakota.cpp (revision 21876) @@ -83,6 +83,10 @@ /* Execute the environment:*/ env.execute(); + xDelete(dakota_input_file); + xDelete(dakota_output_file); + xDelete(dakota_error_file); + /*Return unix success: */ return 0; #else @@ -89,4 +93,5 @@ Cout << "ISSM Dakota executable was compiled without support of Dakota! Will just return now!" << "\n"; return 1; #endif + }