From 1668bcffcf1e4e473d2c9a58ee076a5477474527 Mon Sep 17 00:00:00 2001 From: Steve Plimpton Date: Wed, 28 May 2025 08:53:55 -0600 Subject: [PATCH] fix 2 bugs caught in review --- src/fix_set.cpp | 3 +-- src/set.cpp | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/fix_set.cpp b/src/fix_set.cpp index cab303660b..ac4400c1a9 100644 --- a/src/fix_set.cpp +++ b/src/fix_set.cpp @@ -33,7 +33,7 @@ FixSet::FixSet(LAMMPS *lmp, int narg, char **arg) : Fix(lmp, narg, arg) if (nevery <= 0) error->all(FLERR, "Fix {} Nevery must be > 0", style); reneighbor = utils::inumeric(FLERR, arg[4], false, lmp); - if (reneighbor = 0 || reneighbor > 1) + if (reneighbor < 0 || reneighbor > 1) error->all(FLERR, "Fix {} rnflag must be 0/1", style); // create instance of Set class @@ -83,4 +83,3 @@ void FixSet::end_of_step() if (reneighbor) next_reneighbor = update->ntimestep + 1; } - diff --git a/src/set.cpp b/src/set.cpp index d07b1e4e2c..f42dd175ab 100644 --- a/src/set.cpp +++ b/src/set.cpp @@ -303,7 +303,7 @@ void Set::process_args(int caller_flag, int narg, char **arg) } else if (strcmp(arg[iarg],"smd/mass/density") == 0) { action->keyword = SMD_MASS_DENSITY; process_smd_mass_density(iarg,narg,arg,action); - invoke_choice[naction++] = &Set::invoke_density; + invoke_choice[naction++] = &Set::invoke_smd_mass_density; } else if (strcmp(arg[iarg],"sph/cv") == 0) { action->keyword = SPH_CV; process_sph_cv(iarg,narg,arg,action);