Skip to content

Commit ecb0a9d

Browse files
committed
update the resize
1 parent d8fee18 commit ecb0a9d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

source/module_cell/unitcell.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,10 @@ void UnitCell::setup_cell(const std::string& fn, std::ofstream& log) {
331331
bool ok2 = true;
332332

333333
// (3) read in atom information
334+
this->atom_mass.resize(ntype);
335+
this->atom_label.resize(ntype);
336+
this->pseudo_fn.reszie(ntype);
337+
this->pseudo_type.resize(ntype);
334338
if (GlobalV::MY_RANK == 0) {
335339
// open "atom_unitcell" file.
336340
std::ifstream ifa(fn.c_str(), std::ios::in);

0 commit comments

Comments
 (0)