Skip to content

Commit

Permalink
[python] Use ctypes for parameters of DLL functions for Dataset (#3423)
Browse files Browse the repository at this point in the history
  • Loading branch information
StrikerRUS authored Sep 30, 2020
1 parent f60c14f commit a3862f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python-package/lightgbm/basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -1731,9 +1731,9 @@ def get_feature_name(self):
ptr_string_buffers = (ctypes.c_char_p * num_feature)(*map(ctypes.addressof, string_buffers))
_safe_call(_LIB.LGBM_DatasetGetFeatureNames(
self.handle,
num_feature,
ctypes.c_int(num_feature),
ctypes.byref(tmp_out_len),
reserved_string_buffer_size,
ctypes.c_size_t(reserved_string_buffer_size),
ctypes.byref(required_string_buffer_size),
ptr_string_buffers))
if num_feature != tmp_out_len.value:
Expand Down

0 comments on commit a3862f1

Please sign in to comment.