Fix Clang Static Analyzer "Allocator sizeof operand mismatch" bug.
Signed-off-by: Vinson Lee <v...@freedesktop.org> --- tests/cl/api/create-program-with-binary.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/cl/api/create-program-with-binary.c b/tests/cl/api/create-program-with-binary.c index 4873b76..55457d9 100644 --- a/tests/cl/api/create-program-with-binary.c +++ b/tests/cl/api/create-program-with-binary.c @@ -101,7 +101,7 @@ static cl_program create_binary_program(const piglit_cl_context ctx) goto free_sizes; } - binaries = calloc(sizeof(char*), ctx->num_devices); + binaries = calloc(sizeof(unsigned char*), ctx->num_devices); for (i = 0; i < ctx->num_devices; i++) { binaries[i] = malloc(sizes[i]); } -- 2.2.1 _______________________________________________ Piglit mailing list Piglit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/piglit