Skip to content

Commit

Permalink
Appease compiler warning
Browse files Browse the repository at this point in the history
  • Loading branch information
giacomofiorin committed Feb 20, 2024
1 parent 0bba289 commit 43da335
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/colvarcomp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ cvm::atom_group *colvar::cvc::parse_group(std::string const &conf,
std::string group_conf;

if (key_lookup(conf, group_key, &group_conf)) {

group = new cvm::atom_group(group_key);

if (b_try_scalable) {
Expand All @@ -195,6 +196,8 @@ cvm::atom_group *colvar::cvc::parse_group(std::string const &conf,
COLVARS_INPUT_ERROR);
delete group;
group = nullptr;
// Silence unused variable warning; TODO stop returning a pointer
(void) error_code;
return group;
}

Expand All @@ -221,6 +224,9 @@ cvm::atom_group *colvar::cvc::parse_group(std::string const &conf,
}
}

// Silence unused variable warning; TODO stop returning a pointer
(void) error_code;

return group;
}

Expand Down

0 comments on commit 43da335

Please sign in to comment.