aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/compiler/glsl/linker.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/compiler/glsl/linker.cpp b/src/compiler/glsl/linker.cpp
index 975b299db55..f7b884e0173 100644
--- a/src/compiler/glsl/linker.cpp
+++ b/src/compiler/glsl/linker.cpp
@@ -988,6 +988,13 @@ cross_validate_globals(struct gl_shader_program *prog,
return;
}
+ if (var->data.location_frac != existing->data.location_frac) {
+ linker_error(prog, "explicit components for %s "
+ "`%s' have differing values\n",
+ mode_string(var), var->name);
+ return;
+ }
+
existing->data.location = var->data.location;
existing->data.explicit_location = true;
} else {