net/SocketError: cast to socket_error_t to fix -Wsign-compare
Only relevant on Windows where socket_error_t is a `DWORD` (unsigned).
This commit is contained in:
parent
39937be2e1
commit
c866199d4c
|
@ -176,7 +176,7 @@ IsSocketError(const std::system_error &e) noexcept
|
||||||
static inline bool
|
static inline bool
|
||||||
IsSocketError(const std::system_error &e, socket_error_t code) noexcept
|
IsSocketError(const std::system_error &e, socket_error_t code) noexcept
|
||||||
{
|
{
|
||||||
return IsSocketError(e) && e.code().value() == code;
|
return IsSocketError(e) && static_cast<socket_error_t>(e.code().value()) == code;
|
||||||
}
|
}
|
||||||
|
|
||||||
[[gnu::pure]]
|
[[gnu::pure]]
|
||||||
|
|
Loading…
Reference in New Issue