Fix #119578: crash when node tool does not have geometry as first output socket
This was simply missing a check and error message. The same error message is shown when the node group is used as modifier. Pull Request: https://projects.blender.org/blender/blender/pulls/119604
This commit is contained in:
@@ -403,6 +403,12 @@ static int run_node_group_exec(bContext *C, wmOperator *op)
|
||||
return OPERATOR_CANCELLED;
|
||||
}
|
||||
}
|
||||
if (node_tree->interface_outputs().is_empty() ||
|
||||
!STREQ(node_tree->interface_outputs()[0]->socket_type, "NodeSocketGeometry"))
|
||||
{
|
||||
BKE_report(op->reports, RPT_ERROR, "Node group's first output must be a geometry");
|
||||
return OPERATOR_CANCELLED;
|
||||
}
|
||||
|
||||
IDProperty *properties = replace_inputs_evaluated_data_blocks(*op->properties, *depsgraph);
|
||||
BLI_SCOPED_DEFER([&]() { IDP_FreeProperty_ex(properties, false); });
|
||||
|
||||
Reference in New Issue
Block a user