Skip to content

Commit

Permalink
Update src/c_api.cpp
Browse files Browse the repository at this point in the history
Co-Authored-By: Nikita Titov <[email protected]>
  • Loading branch information
AlbertoEAF and StrikerRUS authored Mar 18, 2020
1 parent 20fbc90 commit fd3eead
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/c_api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ class Booster {
for (const auto& name : boosting_->FeatureNames()) {
if (idx < len) {
std::memcpy(out_strs[idx], name.c_str(), std::min(name.size() + 1, buffer_len));
out_strs[idx][buffer_len-1] = '\0';
out_strs[idx][buffer_len - 1] = '\0';
}
*out_buffer_len = std::max(name.size() + 1, *out_buffer_len);
++idx;
Expand Down

0 comments on commit fd3eead

Please sign in to comment.