fixed deadlock with replica exchange and -maxh
[alexxy/gromacs.git] / src / kernel / md.c
index 0ab2b9313fe62312153b4cdbc654c5592a1e16c2..4bf12a67d321324ae7fb22a25d2fb39f1aa35d53 100644 (file)
@@ -979,8 +979,8 @@ double do_md(FILE *fplog, t_commrec *cr, int nfile, const t_filenm fnm[],
         }
 
         /* < 0 means stop at next step, > 0 means stop at next NS step */
-        if ( (gs.set[eglsSTOPCOND] < 0 ) ||
-             ( (gs.set[eglsSTOPCOND] > 0 ) && ( bNS || ir->nstlist == 0)) )
+        if ( (gs.set[eglsSTOPCOND] < 0) ||
+             ( (gs.set[eglsSTOPCOND] > 0) && (bNStList || ir->nstlist == 0) ) )
         {
             bLastStep = TRUE;
         }