Skip to content

Commit

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

Signed-off-by: Stefan Weil <sw@weilnetz.de>
  • Loading branch information
stweil committed Dec 13, 2022
1 parent 23138ab commit a806d21
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 a806d21

Please sign in to comment.