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

Unified Diff: content/common/gpu/gpu_channel_manager.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
« no previous file with comments | « content/common/gpu/gpu_channel.cc ('k') | content/common/gpu/gpu_command_buffer_stub.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/gpu/gpu_channel_manager.cc
diff --git a/content/common/gpu/gpu_channel_manager.cc b/content/common/gpu/gpu_channel_manager.cc
index d52bca38c8e78b91502d738a6e417968a354b3fe..f17cd7fdb1f342aeb18d63772e6b8a352db748b3 100644
--- a/content/common/gpu/gpu_channel_manager.cc
+++ b/content/common/gpu/gpu_channel_manager.cc
@@ -29,7 +29,8 @@ class GpuChannelManagerMessageFilter : public IPC::MessageFilter {
public:
GpuChannelManagerMessageFilter(
GpuMemoryBufferFactory* gpu_memory_buffer_factory)
- : sender_(NULL), gpu_memory_buffer_factory_(gpu_memory_buffer_factory) {}
+ : sender_(nullptr),
+ gpu_memory_buffer_factory_(gpu_memory_buffer_factory) {}
virtual void OnFilterAdded(IPC::Sender* sender) override {
DCHECK(!sender_);
@@ -38,7 +39,7 @@ class GpuChannelManagerMessageFilter : public IPC::MessageFilter {
virtual void OnFilterRemoved() override {
DCHECK(sender_);
- sender_ = NULL;
+ sender_ = nullptr;
}
virtual bool OnMessageReceived(const IPC::Message& message) override {
@@ -103,7 +104,7 @@ GpuChannelManager::~GpuChannelManager() {
gpu_channels_.clear();
if (default_offscreen_surface_.get()) {
default_offscreen_surface_->Destroy();
- default_offscreen_surface_ = NULL;
+ default_offscreen_surface_ = nullptr;
}
}
@@ -146,7 +147,7 @@ void GpuChannelManager::RemoveRoute(int32 routing_id) {
GpuChannel* GpuChannelManager::LookupChannel(int32 client_id) {
GpuChannelMap::const_iterator iter = gpu_channels_.find(client_id);
if (iter == gpu_channels_.end())
- return NULL;
+ return nullptr;
else
return iter->second;
}
@@ -172,8 +173,8 @@ void GpuChannelManager::OnEstablishChannel(int client_id,
bool allow_future_sync_points) {
IPC::ChannelHandle channel_handle;
- gfx::GLShareGroup* share_group = NULL;
- gpu::gles2::MailboxManager* mailbox_manager = NULL;
+ gfx::GLShareGroup* share_group = nullptr;
+ gpu::gles2::MailboxManager* mailbox_manager = nullptr;
if (share_context) {
if (!share_group_.get()) {
share_group_ = new gfx::GLShareGroup;
« no previous file with comments | « content/common/gpu/gpu_channel.cc ('k') | content/common/gpu/gpu_command_buffer_stub.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698