replace variable length array in Molecule class with new/delete
This commit is contained in:
@ -1111,7 +1111,7 @@ void Molecule::special_generate()
|
||||
{
|
||||
int newton_bond = force->newton_bond;
|
||||
tagint atom1,atom2;
|
||||
int count[natoms];
|
||||
int *count = new int[natoms];
|
||||
|
||||
// temporary array for special atoms
|
||||
|
||||
@ -1197,6 +1197,7 @@ void Molecule::special_generate()
|
||||
}
|
||||
}
|
||||
}
|
||||
delete[] count;
|
||||
|
||||
maxspecial = 0;
|
||||
for (int i = 0; i < natoms; i++)
|
||||
|
||||
Reference in New Issue
Block a user