[Piglit] [PATCH] arb_shader_storage_buffer_object/maxblocks: fail test if glGetIntegerv() gives an error

Samuel Iglesias Gonsalvez siglesias at igalia.com
Fri Jul 10 00:12:04 PDT 2015


Signed-off-by: Samuel Iglesias Gonsalvez <siglesias at igalia.com>
---
 tests/spec/arb_shader_storage_buffer_object/maxblocks.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tests/spec/arb_shader_storage_buffer_object/maxblocks.c b/tests/spec/arb_shader_storage_buffer_object/maxblocks.c
index 74c95fe..d87b58c 100644
--- a/tests/spec/arb_shader_storage_buffer_object/maxblocks.c
+++ b/tests/spec/arb_shader_storage_buffer_object/maxblocks.c
@@ -284,6 +284,9 @@ piglit_display(void)
 	glGetIntegerv(GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS, &max_combined);
 	glGetIntegerv(GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES, &max_combined_out);
 
+	if (!piglit_check_gl_error(GL_NO_ERROR))
+	  return PIGLIT_FAIL;
+
 	printf("Max VS shader storage blocks: %d\n", max_vs);
 	printf("Max FS shader storage blocks: %d\n", max_fs);
 	printf("Max combined shader storage blocks: %d\n", max_combined);
-- 
2.1.4



More information about the Piglit mailing list