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

Unified Diff: blimp/client/core/blimp_client_context_impl.cc

Issue 2299453002: Restrict number of BlimpContents to [0, 1] (Closed)
Patch Set: patch failure fix Created 4 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 | « no previous file | blimp/client/core/contents/blimp_contents_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/client/core/blimp_client_context_impl.cc
diff --git a/blimp/client/core/blimp_client_context_impl.cc b/blimp/client/core/blimp_client_context_impl.cc
index 4ebebde648c30cfb8a3c03536604343eb4b982d8..2795e16a6550b3f4b60423f253472c5992c898e3 100644
--- a/blimp/client/core/blimp_client_context_impl.cc
+++ b/blimp/client/core/blimp_client_context_impl.cc
@@ -88,7 +88,8 @@ void BlimpClientContextImpl::SetDelegate(BlimpClientContextDelegate* delegate) {
std::unique_ptr<BlimpContents> BlimpClientContextImpl::CreateBlimpContents() {
std::unique_ptr<BlimpContents> blimp_contents =
blimp_contents_manager_->CreateBlimpContents();
- delegate_->AttachBlimpContentsHelpers(blimp_contents.get());
+ if (blimp_contents)
+ delegate_->AttachBlimpContentsHelpers(blimp_contents.get());
return blimp_contents;
}
« no previous file with comments | « no previous file | blimp/client/core/contents/blimp_contents_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698