[Piglit] [PATCH] cl-api-create-context-from-type: Remove unused variables.
Vinson Lee
vlee at freedesktop.org
Fri Feb 28 18:58:25 PST 2014
This patch fixes these GCC warnings.
create-context-from-type.c: In function ‘piglit_cl_test’:
create-context-from-type.c:173:24: warning: variable ‘invalid_platform_context_properties’ set but not used [-Wunused-but-set-variable]
cl_context_properties invalid_platform_context_properties[] = {
^
create-context-from-type.c:156:13: warning: unused variable ‘cl_ctx’ [-Wunused-variable]
cl_context cl_ctx;
^
create-context-from-type.c:155:9: warning: unused variable ‘errNo’ [-Wunused-variable]
cl_int errNo;
^
Signed-off-by: Vinson Lee <vlee at freedesktop.org>
---
tests/cl/api/create-context-from-type.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/tests/cl/api/create-context-from-type.c b/tests/cl/api/create-context-from-type.c
index 9c31fff..46095d6 100644
--- a/tests/cl/api/create-context-from-type.c
+++ b/tests/cl/api/create-context-from-type.c
@@ -152,8 +152,6 @@ piglit_cl_test(const int argc,
char test_str[1024];
int i, mask;
- cl_int errNo;
- cl_context cl_ctx;
cl_device_type mixed_device_types;
bool found_invalid_platform = false;
@@ -170,10 +168,6 @@ piglit_cl_test(const int argc,
CL_DEVICE_NAME, (cl_context_properties)env->platform_id,
0
};
- cl_context_properties invalid_platform_context_properties[] = {
- CL_CONTEXT_PLATFORM, (cl_context_properties)NULL,
- 0
- };
cl_context_properties multiple_platform_context_properties[] = {
CL_CONTEXT_PLATFORM, (cl_context_properties)env->platform_id,
CL_CONTEXT_PLATFORM, (cl_context_properties)env->platform_id,
@@ -197,8 +191,6 @@ piglit_cl_test(const int argc,
}
}
free(platform_ids);
- invalid_platform_context_properties[1] =
- (cl_context_properties)invalid_platform_id;
/*** Normal usage ***/
--
1.8.3.2
More information about the Piglit
mailing list