Fixed error in onemols initialization when gcmc uses non-first molecule template

git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@14250 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
athomps
2015-11-11 23:39:25 +00:00
parent 4c19f60606
commit da1a3ac83a

View File

@ -253,8 +253,8 @@ void FixGCMC::options(int narg, char **arg)
error->warning(FLERR,"Molecule template for "
"fix gcmc has multiple molecules");
mode = MOLECULE;
onemols = &atom->molecules[imol];
nmol = onemols[0]->nset;
onemols = atom->molecules;
nmol = onemols[imol]->nset;
iarg += 2;
} else if (strcmp(arg[iarg],"region") == 0) {
if (iarg+2 > narg) error->all(FLERR,"Illegal fix gcmc command");