Cycles: Add strict assert when assigning input socket stack offset
[blender.git] / intern / cycles / render / svm.cpp
index 01fda0a9e019985f7f0b4a2170c1ec398c62de54..656ccbcb70f83854dba233b77130dedc494a9a21 100644 (file)
@@ -246,6 +246,7 @@ int SVMCompiler::stack_assign(ShaderInput *input)
        if(input->stack_offset == SVM_STACK_INVALID) {
                if(input->link) {
                        /* linked to output -> use output offset */
+                       assert(input->link->stack_offset != SVM_STACK_INVALID);
                        input->stack_offset = input->link->stack_offset;
                }
                else {