diff options
Diffstat (limited to 'source/blender/nodes')
-rw-r--r-- | source/blender/nodes/texture/nodes/node_texture_common.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/source/blender/nodes/texture/nodes/node_texture_common.c b/source/blender/nodes/texture/nodes/node_texture_common.c index 6ab8d27f6e6..fec6abbf062 100644 --- a/source/blender/nodes/texture/nodes/node_texture_common.c +++ b/source/blender/nodes/texture/nodes/node_texture_common.c @@ -93,9 +93,12 @@ static void group_copy_inputs(bNode *gnode, bNodeStack **in, bNodeStack *gstack) for (node = ngroup->nodes.first; node; node = node->next) { if (node->type == NODE_GROUP_INPUT) { for (sock = node->outputs.first, a = 0; sock; sock = sock->next, ++a) { - ns = node_get_socket_stack(gstack, sock); - if (ns) - copy_stack(ns, in[a]); + if (in[a]) { /* shouldn't need to check this [#36694] */ + ns = node_get_socket_stack(gstack, sock); + if (ns) { + copy_stack(ns, in[a]); + } + } } } } @@ -114,9 +117,12 @@ static void group_copy_outputs(bNode *gnode, bNodeStack **out, bNodeStack *gstac for (node = ngroup->nodes.first; node; node = node->next) { if (node->type == NODE_GROUP_OUTPUT && (node->flag & NODE_DO_OUTPUT)) { for (sock = node->inputs.first, a = 0; sock; sock = sock->next, ++a) { - ns = node_get_socket_stack(gstack, sock); - if (ns) - copy_stack(out[a], ns); + if (out[a]) { /* shouldn't need to check this [#36694] */ + ns = node_get_socket_stack(gstack, sock); + if (ns) { + copy_stack(out[a], ns); + } + } } break; /* only one active output node */ } |