Cycles: Add strict assert when assigning input socket stack offset
authorSergey Sharybin <sergey.vfx@gmail.com>
Tue, 11 Dec 2018 13:34:28 +0000 (14:34 +0100)
committerSergey Sharybin <sergey.vfx@gmail.com>
Tue, 11 Dec 2018 13:34:52 +0000 (14:34 +0100)
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 {