--- trunk/OOPSE-1.0/libmdtools/SimSetup.cpp 2004/07/27 18:14:16 1419 +++ trunk/OOPSE-1.0/libmdtools/SimSetup.cpp 2004/08/09 14:50:35 1451 @@ -96,6 +96,9 @@ SimSetup::~SimSetup(){ } SimSetup::~SimSetup(){ + // clean up the forcefield + the_ff->cleanMe(); + delete stamps; delete globals; } @@ -114,6 +117,8 @@ void SimSetup::parseFile(char* fileName){ #endif // is_mpi inFileName = fileName; + + globals->initalize(); set_interface_stamps(stamps, globals); #ifdef IS_MPI @@ -827,7 +832,6 @@ void SimSetup::gatherInfo(void){ } } - for (i=0; i < nInfo; i++) { // check for the temperature set flag @@ -847,7 +851,7 @@ void SimSetup::gatherInfo(void){ info[i].thermIntLambda = globals->getThermIntLambda(); info[i].thermIntK = globals->getThermIntK(); - Restraints *myRestraint = new Restraints(tot_nmol, info[i].thermIntLambda, info[i].thermIntK); + Restraints *myRestraint = new Restraints(info[i].thermIntLambda, info[i].thermIntK); info[i].restraint = myRestraint; } else { @@ -1126,8 +1130,6 @@ void SimSetup::finalInfoCheck(void){ MPIcheckPoint(); #endif // is_mpi - // clean up the forcefield - the_ff->cleanMe(); } void SimSetup::initSystemCoords(void){