diff options
Diffstat (limited to 'source/blender/blenkernel/intern/node.c')
-rw-r--r-- | source/blender/blenkernel/intern/node.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/node.c b/source/blender/blenkernel/intern/node.c index 2062cc01d02..97bee320ecb 100644 --- a/source/blender/blenkernel/intern/node.c +++ b/source/blender/blenkernel/intern/node.c @@ -656,7 +656,7 @@ void nodeDetachNode(struct bNode *node) } } -bNodeTree *ntreeAddTree(const char *name, int type, int nodetype) +bNodeTree *ntreeAddTree(Main *bmain, const char *name, int type, int nodetype) { bNodeTree *ntree; bNodeType *ntype; @@ -670,7 +670,7 @@ bNodeTree *ntreeAddTree(const char *name, int type, int nodetype) BLI_strncpy(ntree->id.name + 2, name, sizeof(ntree->id.name)); } else - ntree = BKE_libblock_alloc(&G.main->nodetree, ID_NT, name); + ntree = BKE_libblock_alloc(&bmain->nodetree, ID_NT, name); ntree->type = type; ntree->nodetype = nodetype; |