improve error messages
This commit is contained in:
@ -41,7 +41,7 @@ void WriteCoeff::command(int narg, char **arg)
|
||||
if (domain->box_exist == 0)
|
||||
error->all(FLERR, "Write_coeff command before simulation box is defined");
|
||||
|
||||
if (narg != 1) error->all(FLERR, "Illegal write_coeff command");
|
||||
if (narg != 1) utils::missing_cmd_args(FLERR, "write_coeff", error);
|
||||
|
||||
char *file = utils::strdup(fmt::format("{}.tmp", arg[0]));
|
||||
|
||||
@ -167,6 +167,5 @@ void WriteCoeff::command(int narg, char **arg)
|
||||
fclose(two);
|
||||
platform::unlink(file);
|
||||
}
|
||||
|
||||
delete[] file;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user