Commit 50c2827c authored by Mikaël Salson's avatar Mikaël Salson Committed by Mathieu Giraud

affectanalyser.cpp: Optimize destructor

We absolutely don't need to call getDistinctAffectations to destroy the objects
parent 2d0b5908
......@@ -349,12 +349,8 @@ CountKmerAffectAnalyser::CountKmerAffectAnalyser(IKmerStore<KmerAffect> &kms, co
CountKmerAffectAnalyser::~CountKmerAffectAnalyser() {
set<KmerAffect> affects = this->getDistinctAffectations();
/* Initialize each key with a 0-integer array */
for (set<KmerAffect>::iterator it = affects.begin();
it != affects.end(); it++) {
delete [] counts[*it];
for (auto it : counts) {
delete [] it.second;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment