[Piglit] [PATCH] arb_texture_view: Fix format-security warning.

Vinson Lee vlee at freedesktop.org
Thu Oct 22 15:55:16 PDT 2015


sampling-2d-array-as-2d-layer.c:152:4: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
                        testparams[n].desc);
                        ^~~~~~~~~~~~~~~~~~

Signed-off-by: Vinson Lee <vlee at freedesktop.org>
---
 tests/spec/arb_texture_view/sampling-2d-array-as-2d-layer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/spec/arb_texture_view/sampling-2d-array-as-2d-layer.c b/tests/spec/arb_texture_view/sampling-2d-array-as-2d-layer.c
index 65074d2..8189044 100644
--- a/tests/spec/arb_texture_view/sampling-2d-array-as-2d-layer.c
+++ b/tests/spec/arb_texture_view/sampling-2d-array-as-2d-layer.c
@@ -149,7 +149,7 @@ piglit_display(void)
 			subtest_pass &= test_single_layer(&testparams[n], layer);
 		}
 		piglit_report_subtest_result(subtest_pass ? PIGLIT_PASS : PIGLIT_FAIL,
-			testparams[n].desc);
+			"%s", testparams[n].desc);
 		pass &= subtest_pass;
 	}
 
-- 
2.6.0



More information about the Piglit mailing list