Loading base/include/android-base/unique_fd.h +2 −0 Original line number Diff line number Diff line Loading @@ -116,6 +116,8 @@ class unique_fd_impl final { bool operator<(int rhs) const { return get() < rhs; } bool operator==(int rhs) const { return get() == rhs; } bool operator!=(int rhs) const { return get() != rhs; } bool operator==(const unique_fd_impl& rhs) const { return get() == rhs.get(); } bool operator!=(const unique_fd_impl& rhs) const { return get() != rhs.get(); } // Catch bogus error checks (i.e.: "!fd" instead of "fd != -1"). bool operator!() const = delete; Loading Loading
base/include/android-base/unique_fd.h +2 −0 Original line number Diff line number Diff line Loading @@ -116,6 +116,8 @@ class unique_fd_impl final { bool operator<(int rhs) const { return get() < rhs; } bool operator==(int rhs) const { return get() == rhs; } bool operator!=(int rhs) const { return get() != rhs; } bool operator==(const unique_fd_impl& rhs) const { return get() == rhs.get(); } bool operator!=(const unique_fd_impl& rhs) const { return get() != rhs.get(); } // Catch bogus error checks (i.e.: "!fd" instead of "fd != -1"). bool operator!() const = delete; Loading