gles: Fix compile warnings. (#1070)

* gles: Fix compile warnings.

For 32 and 64-bit Visual Studio and the Android Q NDK.

* Fix formatting violations

Co-authored-by: spauls <spauls@qti.qualcomm.com>
This commit is contained in:
Sreelakshmi Haridas Maruthur
2021-05-18 11:10:24 -06:00
committed by GitHub
parent 17a0d09567
commit 6c8045911a
23 changed files with 136 additions and 210 deletions

View File

@@ -579,7 +579,7 @@ static int create_single_kernel_helper_create_program_offline(
if (error != CL_SUCCESS) return error;
ifs.seekg(0, ifs.end);
int length = ifs.tellg();
size_t length = static_cast<size_t>(ifs.tellg());
ifs.seekg(0, ifs.beg);
// treat modifiedProgram as input for clCreateProgramWithBinary
@@ -1226,7 +1226,7 @@ int is_image_format_supported(cl_context context, cl_mem_flags flags,
list = (cl_image_format *)malloc(count * sizeof(cl_image_format));
if (NULL == list)
{
log_error("Error: unable to allocate %ld byte buffer for image format "
log_error("Error: unable to allocate %zu byte buffer for image format "
"list at %s:%d (err = %d)\n",
count * sizeof(cl_image_format), __FILE__, __LINE__, err);
return 0;