Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLukas Toenne <lukas.toenne@googlemail.com>2012-07-12 19:14:50 +0400
committerLukas Toenne <lukas.toenne@googlemail.com>2012-07-12 19:14:50 +0400
commit18d7a2316678ae7074a7f50c48453933ca7a5fb4 (patch)
treec7932bd1b9dee3b58d96f1f4304aaaa12dbbfccc /source/blender/editors/space_node/node_edit.c
parent126024e537a8d1f7c412abf62be3d5b8e243a7da (diff)
Fix #32051, Ungroup operator crashes. The link iterator can be invalidated when unconnected input links are removed.
Diffstat (limited to 'source/blender/editors/space_node/node_edit.c')
-rw-r--r--source/blender/editors/space_node/node_edit.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/space_node/node_edit.c b/source/blender/editors/space_node/node_edit.c
index 7d76994c07a..c4e72fa4a51 100644
--- a/source/blender/editors/space_node/node_edit.c
+++ b/source/blender/editors/space_node/node_edit.c
@@ -1200,7 +1200,8 @@ static int node_group_ungroup(bNodeTree *ntree, bNode *gnode)
nodeRemLink(wgroup, link);
}
/* restore links from internal nodes */
- for (link = wgroup->links.first; link; link = link->next) {
+ for (link = wgroup->links.first; link; link = linkn) {
+ linkn = link->next;
/* indicates link to group input */
if (!link->fromnode) {
/* NB: can't use find_group_node_input here,