Initializing pointers in PERI, QEQ and REPLICA

This commit is contained in:
Anders Hafreager
2016-11-07 19:58:27 +01:00
parent 77bbf03f0f
commit db0524278a
6 changed files with 14 additions and 15 deletions

View File

@ -33,7 +33,8 @@ using namespace FixConst;
/* ---------------------------------------------------------------------- */
FixEvent::FixEvent(LAMMPS *lmp, int narg, char **arg) :
Fix(lmp, narg, arg)
Fix(lmp, narg, arg), xevent(NULL), xold(NULL), vold(NULL),
imageold(NULL), xorig(NULL), vorig(NULL), imageorig(NULL)
{
if (narg != 3) error->all(FLERR,"Illegal fix event command");
@ -42,14 +43,6 @@ FixEvent::FixEvent(LAMMPS *lmp, int narg, char **arg) :
// perform initial allocation of atom-based array
// register with Atom class
xevent = NULL;
xold = NULL;
vold = NULL;
imageold = NULL;
xorig = NULL;
vorig = NULL;
imageorig = NULL;
grow_arrays(atom->nmax);
atom->add_callback(0);
}