Skip to content

Commit 2d446fc

Browse files
committed
fix a bug to force quit when test
1 parent c680655 commit 2d446fc

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

source/module_cell/module_neighbor/sltk_atom_input.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,12 @@ Atom_input::Atom_input(std::ofstream& ofs_in,
2525
ModuleBase::GlobalFunc::OUT(ofs_in, "Amount(atom number)", amount);
2626
ModuleBase::GlobalFunc::OUT(ofs_in, "Periodic_boundary", periodic_boundary);
2727
ModuleBase::GlobalFunc::OUT(ofs_in, "Searching radius(lat0)", radius);
28-
ModuleBase::WARNING_QUIT("atom_arrange::init", " search radius < 0,forbidden");
2928
}
3029

30+
if (radius < 0.0)
31+
{
32+
ModuleBase::WARNING_QUIT("atom_arrange::init", " search radius < 0,forbidden");
33+
}
3134
// random selection, in order to estimate again.
3235
this->x_min = ucell.atoms[0].tau[0].x;
3336
this->y_min = ucell.atoms[0].tau[0].y;

0 commit comments

Comments
 (0)