From af58f48608e9fcc8ad4b6baf3116bb7cfadbd6fd Mon Sep 17 00:00:00 2001 From: "viettrungluu@chromium.org" Date: Wed, 19 Mar 2014 14:50:21 +0000 Subject: Add an operator!= to base::FileDescriptor. (It already has an operator==.) R=brettw@chromium.org Review URL: https://codereview.chromium.org/203303007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@257962 0039d316-1c4b-4281-b951-d872f2087c98 --- base/file_descriptor_posix.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'base/file_descriptor_posix.h') diff --git a/base/file_descriptor_posix.h b/base/file_descriptor_posix.h index 093dd2f..c730be6 100644 --- a/base/file_descriptor_posix.h +++ b/base/file_descriptor_posix.h @@ -29,6 +29,10 @@ struct FileDescriptor { return (fd == other.fd && auto_close == other.auto_close); } + bool operator!=(const FileDescriptor& other) const { + return !operator==(other); + } + // A comparison operator so that we can use these as keys in a std::map. bool operator<(const FileDescriptor& other) const { return other.fd < fd; -- cgit v1.1