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

Unified Diff: content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc

Issue 649533003: C++11 declares a type safe null pointer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed Presubmit errors Created 6 years, 2 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
Index: content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc
diff --git a/content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc b/content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc
index 83d9dbfdb0945ce46429b17b146ed57b7d8a377b..fd460e40d69f181d00527618fd7ed6a403eacc7b 100644
--- a/content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc
+++ b/content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc
@@ -112,7 +112,7 @@ WebGraphicsContext3DCommandBufferImpl::WebGraphicsContext3DCommandBufferImpl(
WebGraphicsContext3DCommandBufferImpl::
~WebGraphicsContext3DCommandBufferImpl() {
if (real_gl_) {
- real_gl_->SetErrorMessageCallback(NULL);
+ real_gl_->SetErrorMessageCallback(nullptr);
}
Destroy();
@@ -156,7 +156,7 @@ bool WebGraphicsContext3DCommandBufferImpl::InitializeCommandBuffer(
if (!host_.get())
return false;
- CommandBufferProxyImpl* share_group_command_buffer = NULL;
+ CommandBufferProxyImpl* share_group_command_buffer = nullptr;
if (share_context) {
share_group_command_buffer = share_context->command_buffer_.get();
@@ -208,7 +208,7 @@ bool WebGraphicsContext3DCommandBufferImpl::CreateContext(bool onscreen) {
scoped_ptr<base::AutoLock> share_group_lock;
bool add_to_share_group = false;
if (!command_buffer_) {
- WebGraphicsContext3DCommandBufferImpl* share_context = NULL;
+ WebGraphicsContext3DCommandBufferImpl* share_context = nullptr;
share_group_lock.reset(new base::AutoLock(share_group_->lock()));
share_context = share_group_->GetAnyContextLocked();
@@ -295,7 +295,7 @@ void WebGraphicsContext3DCommandBufferImpl::Destroy() {
// issued on this context might not be visible to other contexts in the
// share group.
gl->Flush();
- setGLInterface(NULL);
+ setGLInterface(nullptr);
}
trace_gl_.reset();
@@ -310,7 +310,7 @@ void WebGraphicsContext3DCommandBufferImpl::Destroy() {
command_buffer_.reset();
}
- host_ = NULL;
+ host_ = nullptr;
}
gpu::ContextSupport*
@@ -352,10 +352,10 @@ WebGraphicsContext3DCommandBufferImpl::CreateOffscreenContext(
const SharedMemoryLimits& limits,
WebGraphicsContext3DCommandBufferImpl* share_context) {
if (!host)
- return NULL;
+ return nullptr;
if (share_context && share_context->IsCommandBufferContextLost())
- return NULL;
+ return nullptr;
return new WebGraphicsContext3DCommandBufferImpl(
0,
« no previous file with comments | « content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h ('k') | content/common/gpu/gpu_channel.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698