Skip to content

Commit

Permalink
Merge pull request #83054 from dsnopek/gdextension-validated-call-alw…
Browse files Browse the repository at this point in the history
…ays-ret-pointer

GDExtension: Use correct return pointer for validated calls that return `Variant`
  • Loading branch information
akien-mga committed Oct 10, 2023
2 parents 49cdd33 + 88b6fee commit feb6ea2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/extension/gdextension.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ class GDExtensionMethodBind : public MethodBind {
void *ret_opaque = nullptr;
if (r_ret) {
VariantInternal::initialize(r_ret, return_value_info.type);
ret_opaque = VariantInternal::get_opaque_pointer(r_ret);
ret_opaque = r_ret->get_type() == Variant::NIL ? r_ret : VariantInternal::get_opaque_pointer(r_ret);
}

ptrcall(p_object, argptrs, ret_opaque);
Expand Down

0 comments on commit feb6ea2

Please sign in to comment.