Loading libs/ui/Fence.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -110,7 +110,7 @@ nsecs_t Fence::getSignalTime() const { } struct sync_file_info* finfo = sync_file_info(mFenceFd); if (finfo == NULL) { if (finfo == nullptr) { ALOGE("sync_file_info returned NULL for fd %d", mFenceFd.get()); return SIGNAL_TIME_INVALID; } Loading libs/ui/GraphicBuffer.cpp +8 −8 Original line number Diff line number Diff line Loading @@ -76,7 +76,7 @@ GraphicBuffer::GraphicBuffer() usage_deprecated = 0; usage = 0; layerCount = 0; handle = NULL; handle = nullptr; } // deprecated Loading Loading @@ -143,7 +143,7 @@ void GraphicBuffer::free_handle() GraphicBufferAllocator& allocator(GraphicBufferAllocator::get()); allocator.free(handle); } handle = NULL; handle = nullptr; } status_t GraphicBuffer::initCheck() const { Loading Loading @@ -178,7 +178,7 @@ status_t GraphicBuffer::reallocate(uint32_t inWidth, uint32_t inHeight, if (handle) { GraphicBufferAllocator& allocator(GraphicBufferAllocator::get()); allocator.free(handle); handle = 0; handle = nullptr; } return initWithSize(inWidth, inHeight, inFormat, inLayerCount, inUsage, "[Reallocation]"); } Loading Loading @@ -452,7 +452,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; ALOGE("unflatten: numFds or numInts is too large: %zd, %zd", numFds, numInts); return BAD_VALUE; } Loading Loading @@ -486,7 +486,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; ALOGE("unflatten: native_handle_create failed"); return NO_MEMORY; } Loading @@ -497,7 +497,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; } mId = static_cast<uint64_t>(buf[7]) << 32; Loading @@ -507,7 +507,7 @@ status_t GraphicBuffer::unflatten( mOwner = ownHandle; if (handle != 0) { if (handle != nullptr) { buffer_handle_t importedHandle; status_t err = mBufferMapper.importBuffer(handle, uint32_t(width), uint32_t(height), uint32_t(layerCount), format, usage, uint32_t(stride), &importedHandle); Loading @@ -515,7 +515,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; ALOGE("unflatten: registerBuffer failed: %s (%d)", strerror(-err), err); return err; } Loading libs/ui/Region.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -820,7 +820,7 @@ status_t Region::unflatten(void const* buffer, size_t size) { } if (numRects > (UINT32_MAX / sizeof(Rect))) { android_errorWriteWithInfoLog(0x534e4554, "29983260", -1, NULL, 0); android_errorWriteWithInfoLog(0x534e4554, "29983260", -1, nullptr, 0); return NO_MEMORY; } Loading libs/ui/tools/lutgen.cpp +5 −5 Original line number Diff line number Diff line Loading @@ -85,11 +85,11 @@ static const ColorSpace findColorSpace(const string& name) { static int handleCommandLineArgments(int argc, char* argv[]) { static constexpr const char* OPTSTR = "h:d:s:t:"; static const struct option OPTIONS[] = { { "help", no_argument, 0, 'h' }, { "dimension", required_argument, 0, 'd' }, { "source", required_argument, 0, 's' }, { "target", required_argument, 0, 't' }, { 0, 0, 0, 0 } // termination of the option list { "help", no_argument, nullptr, 'h' }, { "dimension", required_argument, nullptr, 'd' }, { "source", required_argument, nullptr, 's' }, { "target", required_argument, nullptr, 't' }, { nullptr, 0, nullptr, 0 } // termination of the option list }; int opt; Loading Loading
libs/ui/Fence.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -110,7 +110,7 @@ nsecs_t Fence::getSignalTime() const { } struct sync_file_info* finfo = sync_file_info(mFenceFd); if (finfo == NULL) { if (finfo == nullptr) { ALOGE("sync_file_info returned NULL for fd %d", mFenceFd.get()); return SIGNAL_TIME_INVALID; } Loading
libs/ui/GraphicBuffer.cpp +8 −8 Original line number Diff line number Diff line Loading @@ -76,7 +76,7 @@ GraphicBuffer::GraphicBuffer() usage_deprecated = 0; usage = 0; layerCount = 0; handle = NULL; handle = nullptr; } // deprecated Loading Loading @@ -143,7 +143,7 @@ void GraphicBuffer::free_handle() GraphicBufferAllocator& allocator(GraphicBufferAllocator::get()); allocator.free(handle); } handle = NULL; handle = nullptr; } status_t GraphicBuffer::initCheck() const { Loading Loading @@ -178,7 +178,7 @@ status_t GraphicBuffer::reallocate(uint32_t inWidth, uint32_t inHeight, if (handle) { GraphicBufferAllocator& allocator(GraphicBufferAllocator::get()); allocator.free(handle); handle = 0; handle = nullptr; } return initWithSize(inWidth, inHeight, inFormat, inLayerCount, inUsage, "[Reallocation]"); } Loading Loading @@ -452,7 +452,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; ALOGE("unflatten: numFds or numInts is too large: %zd, %zd", numFds, numInts); return BAD_VALUE; } Loading Loading @@ -486,7 +486,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; ALOGE("unflatten: native_handle_create failed"); return NO_MEMORY; } Loading @@ -497,7 +497,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; } mId = static_cast<uint64_t>(buf[7]) << 32; Loading @@ -507,7 +507,7 @@ status_t GraphicBuffer::unflatten( mOwner = ownHandle; if (handle != 0) { if (handle != nullptr) { buffer_handle_t importedHandle; status_t err = mBufferMapper.importBuffer(handle, uint32_t(width), uint32_t(height), uint32_t(layerCount), format, usage, uint32_t(stride), &importedHandle); Loading @@ -515,7 +515,7 @@ status_t GraphicBuffer::unflatten( width = height = stride = format = usage_deprecated = 0; layerCount = 0; usage = 0; handle = NULL; handle = nullptr; ALOGE("unflatten: registerBuffer failed: %s (%d)", strerror(-err), err); return err; } Loading
libs/ui/Region.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -820,7 +820,7 @@ status_t Region::unflatten(void const* buffer, size_t size) { } if (numRects > (UINT32_MAX / sizeof(Rect))) { android_errorWriteWithInfoLog(0x534e4554, "29983260", -1, NULL, 0); android_errorWriteWithInfoLog(0x534e4554, "29983260", -1, nullptr, 0); return NO_MEMORY; } Loading
libs/ui/tools/lutgen.cpp +5 −5 Original line number Diff line number Diff line Loading @@ -85,11 +85,11 @@ static const ColorSpace findColorSpace(const string& name) { static int handleCommandLineArgments(int argc, char* argv[]) { static constexpr const char* OPTSTR = "h:d:s:t:"; static const struct option OPTIONS[] = { { "help", no_argument, 0, 'h' }, { "dimension", required_argument, 0, 'd' }, { "source", required_argument, 0, 's' }, { "target", required_argument, 0, 't' }, { 0, 0, 0, 0 } // termination of the option list { "help", no_argument, nullptr, 'h' }, { "dimension", required_argument, nullptr, 'd' }, { "source", required_argument, nullptr, 's' }, { "target", required_argument, nullptr, 't' }, { nullptr, 0, nullptr, 0 } // termination of the option list }; int opt; Loading