diff options
| author | Rémi Verschelde | 2018-02-20 09:39:18 +0100 |
|---|---|---|
| committer | GitHub | 2018-02-20 09:39:18 +0100 |
| commit | c62a6942dcdf3b1cbdafa3d858cf9694effeee98 (patch) | |
| tree | 79affc1112257c826914f27b950b7b02a404c1c7 /modules/mono/mono_gd/gd_mono_method.cpp | |
| parent | 1a604fc858b1c988b22663c9a6220e897c24df4a (diff) | |
| parent | 72fe70272d540afca691143d3a4f029176e37087 (diff) | |
| download | godot-c62a6942dcdf3b1cbdafa3d858cf9694effeee98.tar.gz godot-c62a6942dcdf3b1cbdafa3d858cf9694effeee98.tar.zst godot-c62a6942dcdf3b1cbdafa3d858cf9694effeee98.zip | |
Diffstat (limited to 'modules/mono/mono_gd/gd_mono_method.cpp')
| -rw-r--r-- | modules/mono/mono_gd/gd_mono_method.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/mono/mono_gd/gd_mono_method.cpp b/modules/mono/mono_gd/gd_mono_method.cpp index df0985f6a..69040a3df 100644 --- a/modules/mono/mono_gd/gd_mono_method.cpp +++ b/modules/mono/mono_gd/gd_mono_method.cpp @@ -230,11 +230,12 @@ String GDMonoMethod::get_signature_desc(bool p_namespaces) const { } void GDMonoMethod::get_parameter_names(Vector<StringName> &names) const { - const char *_names[params_count]; - mono_method_get_param_names(mono_method, _names); + const char *_names = memnew_arr(char, params_count); + mono_method_get_param_names(mono_method, &_names); for (int i = 0; i < params_count; ++i) { - names.push_back(StringName(_names[i])); + names.push_back(StringName(&_names[i])); } + memdelete_arr(_names); } void GDMonoMethod::get_parameter_types(Vector<ManagedType> &types) const { |
