Fixed initialization of arrays in fixes
This commit is contained in:
committed by
Axel Kohlmeyer
parent
265cc14125
commit
07eb1d443b
@ -52,8 +52,6 @@ FixSpring::FixSpring(LAMMPS *lmp, int narg, char **arg) :
|
||||
respa_level_support = 1;
|
||||
ilevel_respa = 0;
|
||||
|
||||
group2 = NULL;
|
||||
|
||||
if (strcmp(arg[3],"tether") == 0) {
|
||||
if (narg != 9) error->all(FLERR,"Illegal fix spring command");
|
||||
styleflag = TETHER;
|
||||
|
||||
@ -34,7 +34,8 @@ using namespace FixConst;
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
FixSpringChunk::FixSpringChunk(LAMMPS *lmp, int narg, char **arg) :
|
||||
Fix(lmp, narg, arg)
|
||||
Fix(lmp, narg, arg),
|
||||
idchunk(NULL), idcom(NULL), com0(NULL), fcom(NULL)
|
||||
{
|
||||
if (narg != 6) error->all(FLERR,"Illegal fix spring/chunk command");
|
||||
|
||||
@ -55,7 +56,6 @@ FixSpringChunk::FixSpringChunk(LAMMPS *lmp, int narg, char **arg) :
|
||||
strcpy(idcom,arg[5]);
|
||||
|
||||
esprings = 0.0;
|
||||
com0 = fcom = NULL;
|
||||
nchunk = 0;
|
||||
}
|
||||
|
||||
|
||||
@ -32,7 +32,8 @@ using namespace FixConst;
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
FixSpringSelf::FixSpringSelf(LAMMPS *lmp, int narg, char **arg) :
|
||||
Fix(lmp, narg, arg)
|
||||
Fix(lmp, narg, arg),
|
||||
xoriginal(NULL)
|
||||
{
|
||||
if ((narg < 4) || (narg > 5))
|
||||
error->all(FLERR,"Illegal fix spring/self command");
|
||||
|
||||
@ -27,7 +27,8 @@ enum{UNKNOWN,GLOBAL,PERATOM};
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
FixStore::FixStore(LAMMPS *lmp, int narg, char **arg) : Fix(lmp, narg, arg)
|
||||
FixStore::FixStore(LAMMPS *lmp, int narg, char **arg) : Fix(lmp, narg, arg),
|
||||
vstore(NULL), astore(NULL), rbuf(NULL)
|
||||
{
|
||||
if (narg != 6) error->all(FLERR,"Illegal fix store command");
|
||||
|
||||
|
||||
@ -26,7 +26,8 @@ using namespace FixConst;
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
FixStoreForce::FixStoreForce(LAMMPS *lmp, int narg, char **arg) :
|
||||
Fix(lmp, narg, arg)
|
||||
Fix(lmp, narg, arg),
|
||||
foriginal(NULL)
|
||||
{
|
||||
if (narg < 3) error->all(FLERR,"Illegal fix store/coord command");
|
||||
|
||||
|
||||
@ -37,7 +37,9 @@ enum{KEYWORD,COMPUTE,FIX,VARIABLE,DNAME,INAME};
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
FixStoreState::FixStoreState(LAMMPS *lmp, int narg, char **arg) :
|
||||
Fix(lmp, narg, arg)
|
||||
Fix(lmp, narg, arg),
|
||||
nvalues(0), which(NULL), argindex(NULL), value2index(NULL), ids(NULL), values(NULL),
|
||||
vbuf(NULL), pack_choice(NULL)
|
||||
{
|
||||
if (narg < 5) error->all(FLERR,"Illegal fix store/state command");
|
||||
|
||||
|
||||
@ -35,7 +35,8 @@ enum{CONSTANT,EQUAL};
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
FixTempBerendsen::FixTempBerendsen(LAMMPS *lmp, int narg, char **arg) :
|
||||
Fix(lmp, narg, arg)
|
||||
Fix(lmp, narg, arg),
|
||||
tstr(NULL), id_temp(NULL), tflag(0)
|
||||
{
|
||||
if (narg != 6) error->all(FLERR,"Illegal fix temp/berendsen command");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user