Skip to content

Commit

Permalink
updated based on comments
Browse files Browse the repository at this point in the history
  • Loading branch information
imatiach-msft committed Mar 15, 2019
1 parent 76f72c4 commit 72dfc37
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions swig/lightgbmlib.i
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@

%inline %{
char * LGBM_BoosterSaveModelToStringSWIG(BoosterHandle handle,
int start_iteration,
int num_iteration,
int64_t buffer_len,
int64_t* out_len) {
int start_iteration,
int num_iteration,
int64_t buffer_len,
int64_t* out_len) {
char* dst = new char[buffer_len];
int result = LGBM_BoosterSaveModelToString(handle, start_iteration, num_iteration, buffer_len, out_len, dst);
// Reallocate to use larger length
Expand All @@ -38,9 +38,9 @@
}

char ** LGBM_BoosterGetEvalNamesSWIG(BoosterHandle handle,
int eval_counts) {
int eval_counts) {
char** dst = new char*[eval_counts];
for (int i = 0; i < eval_counts; i++) {
for (int i = 0; i < eval_counts; ++i) {
dst[i] = new char[128];
}
int result = LGBM_BoosterGetEvalNames(handle, &eval_counts, dst);
Expand Down

0 comments on commit 72dfc37

Please sign in to comment.