use strmatch() consistently to detect respa and verlet runstyles with optional suffix
This commit is contained in:
@ -166,7 +166,7 @@ void FixSetForce::init()
|
||||
varflag = EQUAL;
|
||||
else varflag = CONSTANT;
|
||||
|
||||
if (strstr(update->integrate_style,"respa")) {
|
||||
if (utils::strmatch(update->integrate_style,"^respa")) {
|
||||
nlevels_respa = ((Respa *) update->integrate)->nlevels;
|
||||
if (respa_level >= 0) ilevel_respa = MIN(respa_level,nlevels_respa-1);
|
||||
else ilevel_respa = nlevels_respa-1;
|
||||
@ -192,7 +192,7 @@ void FixSetForce::init()
|
||||
|
||||
void FixSetForce::setup(int vflag)
|
||||
{
|
||||
if (strstr(update->integrate_style,"verlet"))
|
||||
if (utils::strmatch(update->integrate_style,"^verlet"))
|
||||
post_force(vflag);
|
||||
else
|
||||
for (int ilevel = 0; ilevel < nlevels_respa; ilevel++) {
|
||||
|
||||
Reference in New Issue
Block a user