[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [33506] branches/particles-2010/source/ blender/editors/space_node/node_draw.c: Fixed crash when drawing muted nodes.

Lukas Toenne lukas.toenne at googlemail.com
Mon Dec 6 14:33:45 CET 2010


Revision: 33506
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=33506
Author:   lukastoenne
Date:     2010-12-06 14:33:45 +0100 (Mon, 06 Dec 2010)

Log Message:
-----------
Fixed crash when drawing muted nodes. Muting currently just disables simulation nodes.

Modified Paths:
--------------
    branches/particles-2010/source/blender/editors/space_node/node_draw.c

Modified: branches/particles-2010/source/blender/editors/space_node/node_draw.c
===================================================================
--- branches/particles-2010/source/blender/editors/space_node/node_draw.c	2010-12-06 12:36:55 UTC (rev 33505)
+++ branches/particles-2010/source/blender/editors/space_node/node_draw.c	2010-12-06 13:33:45 UTC (rev 33506)
@@ -483,6 +483,10 @@
 	bNodeLink link= {0};
 	int a;
 	
+	/* clear */
+	for (a=0; a < NUM_SOCKET_TYPES; ++a)
+		input[a] = NULL;
+	
 	/* connect the first input of each type with first output of the same type */
 	
 	/* test the inputs */
@@ -502,9 +506,11 @@
 		for(a=0, sock= node->outputs.first; sock; sock= sock->next, a++) {
 			if(nodeCountSocketLinks(snode->edittree, sock)) {
 				link.tosock= sock;
+				link.tonode= node;
 				
 				if(input[sock->type]) {
 					link.fromsock= input[sock->type];
+					link.fromnode= node;
 					node_draw_link_bezier(v2d, snode, &link, TH_WIRE, TH_WIRE, 0);
 					input[sock->type]= NULL;
 				}





More information about the Bf-blender-cvs mailing list