Fix argument metadata when binding methods
While there doesn't seem to be any runtime issues,
this triggers the address sanitizer in a few ways,
depending on what kind of method you're
binding.
(cherry picked from commit 2b34bd0d8b
)
pull/1527/head
parent
18c31e3e31
commit
80aec184df
|
@ -132,7 +132,7 @@ public:
|
|||
std::vector<GDExtensionClassMethodArgumentMetadata> vec;
|
||||
// First element is return value
|
||||
vec.reserve(argument_count + 1);
|
||||
for (int i = 0; i < argument_count; i++) {
|
||||
for (int i = 0; i < argument_count + 1; i++) {
|
||||
vec.push_back(get_argument_metadata(i - 1));
|
||||
}
|
||||
return vec;
|
||||
|
|
Loading…
Reference in New Issue