use get_(fix|compute)_by_id() instead of find_(fix|compute)()

This commit is contained in:
Axel Kohlmeyer
2021-10-20 02:47:26 -04:00
parent 8cd4460c62
commit 2e362b1f3f
10 changed files with 268 additions and 345 deletions

View File

@ -445,8 +445,7 @@ void ReadRestart::command(int narg, char **arg)
if (nextra) {
memory->destroy(atom->extra);
memory->create(atom->extra,atom->nmax,nextra,"atom:extra");
int ifix = modify->find_fix("_read_restart");
FixReadRestart *fix = (FixReadRestart *) modify->fix[ifix];
auto fix = (FixReadRestart *) modify->get_fix_by_id("_read_restart");
int *count = fix->count;
double **extra = fix->extra;
double **atom_extra = atom->extra;