Fix #136131: crash calling valid_socket_type on custom node trees

This was likely introduced when `socket_type->idname` was changed
from `char[]` to `std::string`.
This commit is contained in:
Jacques Lucke
2025-03-25 13:38:01 +01:00
parent d3431f2d33
commit 6eac902c90

View File

@@ -1011,7 +1011,7 @@ static bool rna_NodeTree_valid_socket_type(blender::bke::bNodeTreeType *ntreetyp
func = &rna_NodeTree_valid_socket_type_func;
RNA_parameter_list_create(&list, &ptr, func);
RNA_parameter_set_lookup(&list, "idname", &socket_type->idname);
RNA_parameter_set_lookup(&list, "idname", socket_type->idname.c_str());
ntreetype->rna_ext.call(nullptr, &ptr, func, &list);
RNA_parameter_get_lookup(&list, "valid", &ret);