From f541b99855bd70781f8d7d655ab259ff9eb596f0 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 11 Jul 2016 14:32:07 +0200 Subject: loplugin:nullptr: Better heuristic to determine code shared between C and C++ Change-Id: I51e1c5fa4639e51fac90f92adf3d87d12960d589 --- opencl/inc/opencl_device_selection.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'opencl') diff --git a/opencl/inc/opencl_device_selection.h b/opencl/inc/opencl_device_selection.h index 74d8d3767d97..0b0ee4edf111 100644 --- a/opencl/inc/opencl_device_selection.h +++ b/opencl/inc/opencl_device_selection.h @@ -146,18 +146,18 @@ inline ds_status initDSProfile(std::unique_ptr& rProfile, OString co rProfile = std::unique_ptr(new ds_profile(rVersion)); - clGetPlatformIDs(0, NULL, &numPlatforms); + clGetPlatformIDs(0, nullptr, &numPlatforms); if (numPlatforms != 0) { platforms.resize(numPlatforms); - clGetPlatformIDs(numPlatforms, platforms.data(), NULL); + clGetPlatformIDs(numPlatforms, platforms.data(), nullptr); } numDevices = 0; for (i = 0; i < (unsigned int)numPlatforms; i++) { cl_uint num = 0; - cl_int err = clGetDeviceIDs(platforms[i], CL_DEVICE_TYPE_ALL, 0, NULL, &num); + cl_int err = clGetDeviceIDs(platforms[i], CL_DEVICE_TYPE_ALL, 0, nullptr, &num); if (err != CL_SUCCESS) { /* we want to catch at least the case when the call returns -- cgit v1.2.3