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

Unified Diff: content/child/child_thread_impl.cc

Issue 1336733002: Re-land: cc: Implement shared worker contexts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix LayerTreeHostClientTakeAwayOutputSurface test. Content provider is always destroyed on the clie… Created 5 years, 3 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/child/child_thread_impl.cc
diff --git a/content/child/child_thread_impl.cc b/content/child/child_thread_impl.cc
index 890b30a7712e4a7bfb95964314b9722d56ba8441..2633b741bd5afa0453c3ee07e369ae6a9a29b857 100644
--- a/content/child/child_thread_impl.cc
+++ b/content/child/child_thread_impl.cc
@@ -595,7 +595,7 @@ scoped_ptr<base::SharedMemory> ChildThreadImpl::AllocateSharedMemory(
shared_buf.reset(new base::SharedMemory);
if (!shared_buf->CreateAnonymous(buf_size)) {
NOTREACHED();
- return NULL;
+ return nullptr;
}
#else
// On POSIX, we need to ask the browser to create the shared memory for us,
@@ -607,11 +607,11 @@ scoped_ptr<base::SharedMemory> ChildThreadImpl::AllocateSharedMemory(
shared_buf.reset(new base::SharedMemory(shared_mem_handle, false));
} else {
NOTREACHED() << "Browser failed to allocate shared memory";
- return NULL;
+ return nullptr;
}
} else {
- NOTREACHED() << "Browser allocation request message failed";
- return NULL;
+ // Send is allowed to fail during shutdown. Return null in this case.
+ return nullptr;
}
#endif
return shared_buf;
« no previous file with comments | « content/browser/compositor/gpu_process_transport_factory.cc ('k') | content/renderer/gpu/compositor_output_surface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698