Added few more stubs so that control reaches to DestroyDevice().
[mesa.git] / src / compiler / glsl / link_uniforms.cpp
index c7ca7034a513b9e0c7d307db4df30fa009febd06..6518ec10f34f9b27ad0e8fecbd603a0be6fe0ee5 100644 (file)
@@ -1059,7 +1059,8 @@ private:
       this->uniforms[id].opaque[shader_type].index = ~0;
       this->uniforms[id].opaque[shader_type].active = false;
 
-      this->uniforms[id].active_shader_mask |= 1 << shader_type;
+      if (current_var->data.used || base_type->is_subroutine())
+         this->uniforms[id].active_shader_mask |= 1 << shader_type;
 
       /* This assigns uniform indices to sampler and image uniforms. */
       handle_samplers(base_type, &this->uniforms[id], name);