Skip to content

Commit

Permalink
Fix function ReadTrainingSamples (issue #3965)
Browse files Browse the repository at this point in the history
This fixes duplicate delete when running cntraining.

Signed-off-by: Stefan Weil <[email protected]>
  • Loading branch information
stweil committed Dec 11, 2022
1 parent 77573b3 commit 8a62630
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/training/common/commontraining.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,7 @@ void ReadTrainingSamples(const FEATURE_DEFS_STRUCT &feature_definitions, const c
if (feature_type != i) {
delete char_desc->FeatureSets[i];
}
char_desc->FeatureSets[i] = nullptr;
}
delete char_desc;
}
Expand Down

0 comments on commit 8a62630

Please sign in to comment.