diff options
author | Max Kellermann <max@musicpd.org> | 2017-08-10 17:37:08 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2017-08-10 17:37:08 +0200 |
commit | 39f422ded8c98dc0b18f635eb81cccf302aa8168 (patch) | |
tree | e64c25444706df14c1baf138c7754accc6e15c80 /src | |
parent | d2cdaa041cf9759f7e133663beab505ccee8e05a (diff) |
net/SocketDescriptor: allow constructing with "int"
Diffstat (limited to 'src')
-rw-r--r-- | src/net/SocketDescriptor.hxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/net/SocketDescriptor.hxx b/src/net/SocketDescriptor.hxx index 33785cd8c..6b2c6bdfa 100644 --- a/src/net/SocketDescriptor.hxx +++ b/src/net/SocketDescriptor.hxx @@ -42,15 +42,15 @@ class StaticSocketAddress; */ class SocketDescriptor : protected FileDescriptor { protected: - explicit constexpr SocketDescriptor(int _fd) - :FileDescriptor(_fd) {} - explicit constexpr SocketDescriptor(FileDescriptor _fd) :FileDescriptor(_fd) {} public: SocketDescriptor() = default; + explicit constexpr SocketDescriptor(int _fd) + :FileDescriptor(_fd) {} + constexpr bool operator==(SocketDescriptor other) const { return fd == other.fd; } |