Merge branch release-2016
[alexxy/gromacs.git] / src / gromacs / mdlib / minimize.cpp
index b3529be7ca456cbb6aebbc94146c952b06df4ea5..d959351aef40b5ae2fcc2d14a6409efc95147dcf 100644 (file)
@@ -405,14 +405,14 @@ void init_em(FILE *fplog, const char *title,
                                   graph, mdatoms,
                                   vsite, shellfc ? *shellfc : nullptr);
 
-        update_mdatoms(mdatoms, state_global->lambda[efptFEP]);
-
         if (vsite)
         {
             set_vsite_top(vsite, *top, mdatoms, cr);
         }
     }
 
+    update_mdatoms(mdatoms, state_global->lambda[efptMASS]);
+
     if (constr)
     {
         if (ir->eConstrAlg == econtSHAKE &&