address unititialized data warnings from coverity scan
This commit is contained in:
@ -50,7 +50,7 @@ using namespace MathConst;
|
||||
|
||||
// XYZ PLANE need to be 0,1,2
|
||||
|
||||
enum {XPLANE=0,YPLANE=1,ZPLANE=2,ZCYLINDER,REGION};
|
||||
enum {NOSTYLE=-1,XPLANE=0,YPLANE=1,ZPLANE=2,ZCYLINDER,REGION};
|
||||
|
||||
enum {NONE,CONSTANT,EQUAL};
|
||||
enum {DAMPING_NONE, VELOCITY, MASS_VELOCITY, VISCOELASTIC, TSUJI};
|
||||
@ -371,7 +371,7 @@ FixWallGran::FixWallGran(LAMMPS *lmp, int narg, char **arg) :
|
||||
wallstyle = REGION;
|
||||
idregion = utils::strdup(arg[iarg+1]);
|
||||
iarg += 2;
|
||||
}
|
||||
} else wallstyle = NOSTYLE;
|
||||
|
||||
// optional args
|
||||
|
||||
@ -407,6 +407,8 @@ FixWallGran::FixWallGran(LAMMPS *lmp, int narg, char **arg) :
|
||||
} else error->all(FLERR,"Illegal fix wall/gran command");
|
||||
}
|
||||
|
||||
if (wallstyle == NOSTYLE)
|
||||
error->all(FLERR,"No wall style defined");
|
||||
if (wallstyle == XPLANE && domain->xperiodic)
|
||||
error->all(FLERR,"Cannot use wall in periodic dimension");
|
||||
if (wallstyle == YPLANE && domain->yperiodic)
|
||||
|
||||
@ -69,7 +69,7 @@ class FixOrientBCC : public Fix {
|
||||
char *xifilename, *chifilename; // file names for 2 crystal orientations
|
||||
|
||||
bool use_xismooth;
|
||||
double Rxi[8][3], Rchi[8][3], half_xi_chi_vec[2][4][3];
|
||||
double Rxi[8][3] = {0}, Rchi[8][3] = {0}, half_xi_chi_vec[2][4][3] = {0};
|
||||
double xiid, xi0, xi1, xicutoffsq, cutsq, added_energy;
|
||||
int half_bcc_nn;
|
||||
|
||||
|
||||
@ -69,7 +69,7 @@ class FixOrientFCC : public Fix {
|
||||
char *xifilename, *chifilename; // file names for 2 crystal orientations
|
||||
|
||||
bool use_xismooth;
|
||||
double Rxi[12][3], Rchi[12][3], half_xi_chi_vec[2][6][3];
|
||||
double Rxi[8][3] = {0}, Rchi[8][3] = {0}, half_xi_chi_vec[2][4][3] = {0};
|
||||
double xiid, xi0, xi1, xicutoffsq, cutsq, added_energy;
|
||||
int half_fcc_nn;
|
||||
|
||||
|
||||
@ -31,7 +31,7 @@ using namespace LAMMPS_NS;
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
RegCone::RegCone(LAMMPS *lmp, int narg, char **arg) :
|
||||
Region(lmp, narg, arg)
|
||||
Region(lmp, narg, arg), lo(0.0), hi(0.0)
|
||||
{
|
||||
options(narg-9,&arg[9]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user