Commit dd2b2043 authored by Vinson Lee's avatar Vinson Lee
Browse files

util-cl: Fix non-portable sizeof.



Fix Coverity "sizeof not portable" defect.
Signed-off-by: Vinson Lee's avatarVinson Lee <vlee@freedesktop.org>
Reviewed-by: Jan Vesely's avatarJan Vesely <jan.vesely@rutgers.edu>
parent 5a11ead2
......@@ -287,7 +287,7 @@ piglit_cl_program_test_run(const int argc,
} else if(config->program_binary_file != NULL) {
unsigned int length;
size_t* lengths = malloc(sizeof(size_t) * env.context->num_devices);
unsigned char** program_binaries = malloc(sizeof(unsigned char**) * env.context->num_devices);
unsigned char** program_binaries = malloc(sizeof(unsigned char*) * env.context->num_devices);
((char**)program_binaries)[0] =
piglit_load_text_file(config->program_binary_file, &length);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment