[Piglit] [PATCH] degenerate-prims: fix incorrect return value from test_prim()

Brian Paul brianp at vmware.com
Tue Feb 13 21:26:18 UTC 2018


The function is supposed to return a piglit_result, not true/false.
Fixes incorrect 'fail' results.
---
 tests/general/degenerate-prims.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/general/degenerate-prims.c b/tests/general/degenerate-prims.c
index 0eed99c..3001d34 100644
--- a/tests/general/degenerate-prims.c
+++ b/tests/general/degenerate-prims.c
@@ -72,7 +72,7 @@ test_prim(void *_data)
 	piglit_report_subtest_result(pass ? PIGLIT_PASS : PIGLIT_FAIL,
 			             "Primitive: %s", piglit_get_prim_name(data->prim));
 
-	return pass;
+	return pass ? PIGLIT_PASS : PIGLIT_FAIL;
 }
 
 
-- 
2.7.4



More information about the Piglit mailing list