Skip to content
Snippets Groups Projects
Commit 392bac36 authored by Giovanni Bussi's avatar Giovanni Bussi
Browse files

Moved cmd("setStopFlag") to be after cmd("init")

I think this is more coherent with other cmd() calls.
parent 6a7c6e42
No related branches found
No related tags found
No related merge requests found
......@@ -257,7 +257,6 @@ int Driver<real>::main(FILE* in,FILE*out,Communicator& pc){
p.cmd("setRealPrecision",&rr);
int checknatoms=-1;
int plumedStopCondition=0;
p.cmd("setStopFlag",&plumedStopCondition);
int step=0;
if(Communicator::initialized()){
if(multi){
......@@ -422,6 +421,7 @@ int Driver<real>::main(FILE* in,FILE*out,Communicator& pc){
}
p.cmd("setStep",&step);
p.cmd("setStopFlag",&plumedStopCondition);
if(!noatoms){
if(trajectory_fmt=="xyz"){
if(!Tools::getline(fp,line)) error("premature end of trajectory file");
......
......@@ -289,11 +289,11 @@ void PlumedMain::cmd(const std::string & word,void*val){
CHECK_NOTINIT(initialized,word);
CHECK_NULL(val,word);
log.open(static_cast<char*>(val),"w");
// other commands that should be used after initialization:
} else if(word=="setStopFlag"){
CHECK_NOTINIT(initialized,word);
CHECK_INIT(initialized,word);
CHECK_NULL(val,word);
stopFlag=static_cast<int*>(val);
// other commands that should be used after initialization:
} else if(word=="getExchangesFlag"){
CHECK_INIT(initialized,word);
CHECK_NULL(val,word);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment