Fixed initialization of arrays in computes

This commit is contained in:
Anders Hafreager
2016-08-24 16:38:30 +02:00
committed by Axel Kohlmeyer
parent 1f3ef8e0ee
commit fcd54f02e6
5 changed files with 10 additions and 14 deletions

View File

@ -33,7 +33,8 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
ComputePEAtom::ComputePEAtom(LAMMPS *lmp, int narg, char **arg) :
Compute(lmp, narg, arg)
Compute(lmp, narg, arg),
energy(NULL)
{
if (narg < 3) error->all(FLERR,"Illegal compute pe/atom command");
@ -68,7 +69,6 @@ ComputePEAtom::ComputePEAtom(LAMMPS *lmp, int narg, char **arg) :
}
nmax = 0;
energy = NULL;
}
/* ---------------------------------------------------------------------- */