Fix crash opening specific files
For some reason socket flag and actual presence of link got out of sync. Check for link to be present prior to access it. Fixes crash opening file from T48684.
This commit is contained in:
parent
9483997472
commit
a6d01365e3
|
@ -1219,7 +1219,7 @@ static void update_noise_and_wave_distortion(bNodeTree *ntree)
|
|||
bNodeSocket *sockDistortion = nodeFindSocket(node, SOCK_IN, "Distortion");
|
||||
float *distortion = cycles_node_socket_float_value(sockDistortion);
|
||||
|
||||
if (socket_is_used(sockDistortion)) {
|
||||
if (socket_is_used(sockDistortion) && sockDistortion->link != NULL) {
|
||||
bNode *distortionInputNode = sockDistortion->link->fromnode;
|
||||
bNodeSocket *distortionInputSock = sockDistortion->link->fromsock;
|
||||
|
||||
|
|
Loading…
Reference in New Issue