Merge pull request #653 from jdevemy/master

Bugfix for the limit keyword
This commit is contained in:
Steve Plimpton 2017-09-15 15:21:53 -06:00 committed by GitHub
commit 5f6937dadd
1 changed files with 3 additions and 3 deletions

View File

@ -218,10 +218,10 @@ ComputeChunkAtom::ComputeChunkAtom(LAMMPS *lmp, int narg, char **arg) :
if (limit && !compress) limitfirst = 1; if (limit && !compress) limitfirst = 1;
iarg += 2; iarg += 2;
if (limit) { if (limit) {
if (iarg+1 > narg) if (iarg > narg)
error->all(FLERR,"Illegal compute chunk/atom command"); error->all(FLERR,"Illegal compute chunk/atom command");
if (strcmp(arg[iarg+1],"max") == 0) limitstyle = LIMITMAX; if (strcmp(arg[iarg],"max") == 0) limitstyle = LIMITMAX;
else if (strcmp(arg[iarg+1],"exact") == 0) limitstyle = LIMITEXACT; else if (strcmp(arg[iarg],"exact") == 0) limitstyle = LIMITEXACT;
else error->all(FLERR,"Illegal compute chunk/atom command"); else error->all(FLERR,"Illegal compute chunk/atom command");
iarg++; iarg++;
} }