Solve possible buffer overrun when using too much closures
Solve possible buffer overrun when using too much closures

Glass BSDF was doing some magic with copying weigths from initial closure
onto refraction one and the code was not checking properly for the number
of closures.

tangent-opensource/coreBlackbird,tangent-opensource/coreBlackbird,tangent-opensource/coreBlackbird