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

Unified Diff: mojo/public/cpp/bindings/binding.h

Issue 1880353004: PaymentRequest should be a ContextLifecycleObserver (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: V2 Created 4 years, 8 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: mojo/public/cpp/bindings/binding.h
diff --git a/mojo/public/cpp/bindings/binding.h b/mojo/public/cpp/bindings/binding.h
index 68dd32239c41c3d1682c5ca12303f95bf7f16089..3426a30921f2e0d699205707ce6fd222e253bc04 100644
--- a/mojo/public/cpp/bindings/binding.h
+++ b/mojo/public/cpp/bindings/binding.h
@@ -156,7 +156,7 @@ class Binding {
// Closes the message pipe that was previously bound. Put this object into a
// state where it can be rebound to a new pipe.
- void Close() { internal_state_.Close(); }
+ void Close() { if (internal_state_.is_bound()) internal_state_.Close(); }
please use gerrit instead 2016/04/13 22:56:46 Instead of checking is_bound() here, let's check i
rwlbuis 2016/04/14 00:28:33 Done.
// Unbinds the underlying pipe from this binding and returns it so it can be
// used in another context, such as on another thread or with a different

Powered by Google App Engine
This is Rietveld 408576698