Index: mojo/public/cpp/system/handle.h |
diff --git a/mojo/public/cpp/system/handle.h b/mojo/public/cpp/system/handle.h |
index f83a9226f1891e2904341f54d01c75d32bfb8678..d0466b0ddead9ae80b1b8e95964df058fda19b37 100644 |
--- a/mojo/public/cpp/system/handle.h |
+++ b/mojo/public/cpp/system/handle.h |
@@ -122,6 +122,10 @@ class ScopedHandleBase { |
bool is_valid() const { return handle_.is_valid(); } |
+ bool operator==(const ScopedHandleBase& other) const { |
+ return handle_.value() == other.get().value(); |
+ } |
+ |
private: |
void CloseIfNecessary() { |
if (handle_.is_valid()) |