Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(586)

Unified Diff: src/utils/SkThreadUtils_win.cpp

Issue 1316233002: Style Change: NULL->nullptr (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-27 (Thursday) 10:25:06 EDT Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/utils/SkThreadUtils_pthread.cpp ('k') | src/utils/android/SkAndroidSDKCanvas.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/utils/SkThreadUtils_win.cpp
diff --git a/src/utils/SkThreadUtils_win.cpp b/src/utils/SkThreadUtils_win.cpp
index a064d3b6b3102fc1cc8947ec4b3061a928df1bf0..a5efb939f33254d4b7dd7c87d294f5bc532f0e70 100644
--- a/src/utils/SkThreadUtils_win.cpp
+++ b/src/utils/SkThreadUtils_win.cpp
@@ -11,17 +11,17 @@
#include "SkThreadUtils_win.h"
SkThread_WinData::SkThread_WinData(SkThread::entryPointProc entryPoint, void* data)
- : fHandle(NULL)
+ : fHandle(nullptr)
, fParam(data)
, fThreadId(0)
, fEntryPoint(entryPoint)
, fStarted(false)
{
fCancelEvent = CreateEvent(
- NULL, // default security attributes
+ nullptr, // default security attributes
false, //auto reset
false, //not signaled
- NULL); //no name
+ nullptr); //no name
}
SkThread_WinData::~SkThread_WinData() {
@@ -44,12 +44,12 @@ SkThread::SkThread(entryPointProc entryPoint, void* data) {
SkThread_WinData* winData = new SkThread_WinData(entryPoint, data);
fData = winData;
- if (NULL == winData->fCancelEvent) {
+ if (nullptr == winData->fCancelEvent) {
return;
}
winData->fHandle = CreateThread(
- NULL, // default security attributes
+ nullptr, // default security attributes
0, // use default stack size
thread_start, // thread function name (proxy)
winData, // argument to thread function (proxy args)
@@ -58,10 +58,10 @@ SkThread::SkThread(entryPointProc entryPoint, void* data) {
}
SkThread::~SkThread() {
- if (fData != NULL) {
+ if (fData != nullptr) {
SkThread_WinData* winData = static_cast<SkThread_WinData*>(fData);
// If created thread but start was never called, kill the thread.
- if (winData->fHandle != NULL && !winData->fStarted) {
+ if (winData->fHandle != nullptr && !winData->fStarted) {
if (SetEvent(winData->fCancelEvent) != 0) {
if (this->start()) {
this->join();
@@ -77,7 +77,7 @@ SkThread::~SkThread() {
bool SkThread::start() {
SkThread_WinData* winData = static_cast<SkThread_WinData*>(fData);
- if (NULL == winData->fHandle) {
+ if (nullptr == winData->fHandle) {
return false;
}
@@ -90,7 +90,7 @@ bool SkThread::start() {
void SkThread::join() {
SkThread_WinData* winData = static_cast<SkThread_WinData*>(fData);
- if (NULL == winData->fHandle || !winData->fStarted) {
+ if (nullptr == winData->fHandle || !winData->fStarted) {
return;
}
@@ -119,7 +119,7 @@ static unsigned int nth_set_bit(unsigned int n, DWORD_PTR mask) {
bool SkThread::setProcessorAffinity(unsigned int processor) {
SkThread_WinData* winData = static_cast<SkThread_WinData*>(fData);
- if (NULL == winData->fHandle) {
+ if (nullptr == winData->fHandle) {
return false;
}
« no previous file with comments | « src/utils/SkThreadUtils_pthread.cpp ('k') | src/utils/android/SkAndroidSDKCanvas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698