try to suppress false positive from static code analysis (natom is always > 0)
This commit is contained in:
@ -684,7 +684,7 @@ void FixPour::pre_exchange()
|
|||||||
// warn if not successful with all insertions b/c too many attempts
|
// warn if not successful with all insertions b/c too many attempts
|
||||||
|
|
||||||
int ninserted_atoms = nnear - nprevious;
|
int ninserted_atoms = nnear - nprevious;
|
||||||
int ninserted_mols = ninserted_atoms / natom;
|
int ninserted_mols = ninserted_atoms / natom; // clang_sa_ignore [core.DivideZero]
|
||||||
ninserted += ninserted_mols;
|
ninserted += ninserted_mols;
|
||||||
if (ninserted_mols < nnew && me == 0) error->warning(FLERR, "Fewer insertions than requested");
|
if (ninserted_mols < nnew && me == 0) error->warning(FLERR, "Fewer insertions than requested");
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user