make certain class member list is initialized to NULL before assigned to a neighbor list

This commit is contained in:
Axel Kohlmeyer 2017-06-20 16:09:11 -04:00
parent 87c028ed02
commit cccf72a21d
2 changed files with 2 additions and 2 deletions

View File

@ -50,7 +50,7 @@ enum{NCOMMON};
ComputeCNPAtom::ComputeCNPAtom(LAMMPS *lmp, int narg, char **arg) :
Compute(lmp, narg, arg),
nearest(NULL), nnearest(NULL), cnpv(NULL)
list(NULL), nearest(NULL), nnearest(NULL), cnpv(NULL)
{
if (narg != 4) error->all(FLERR,"Illegal compute cnp/atom command");

View File

@ -43,7 +43,7 @@ enum{NCOMMON,NBOND,MAXBOND,MINBOND};
ComputeCNAAtom::ComputeCNAAtom(LAMMPS *lmp, int narg, char **arg) :
Compute(lmp, narg, arg),
nearest(NULL), nnearest(NULL), pattern(NULL)
list(NULL), nearest(NULL), nnearest(NULL), pattern(NULL)
{
if (narg != 4) error->all(FLERR,"Illegal compute cna/atom command");