diff options
| author | 2020-10-13 08:10:50 -0400 | |
|---|---|---|
| committer | 2020-10-13 13:16:49 -0400 | |
| commit | 39c8d18feba8eafcd43fbb55e73ae150a1947aad (patch) | |
| tree | 9565ff464bbb9e5a0aa66e6e310098314e88d019 /src/core/hle/service/sockets | |
| parent | Merge pull request #3929 from FearlessTobi/ticket-keys (diff) | |
| download | yuzu-39c8d18feba8eafcd43fbb55e73ae150a1947aad.tar.gz yuzu-39c8d18feba8eafcd43fbb55e73ae150a1947aad.tar.xz yuzu-39c8d18feba8eafcd43fbb55e73ae150a1947aad.zip | |
core/CMakeLists: Make some warnings errors
Makes our error coverage a little more consistent across the board by
applying it to Linux side of things as well. This also makes it more
consistent with the warning settings in other libraries in the project.
This also updates httplib to 0.7.9, as there are several warning
cleanups made that allow us to enable several warnings as errors.
Diffstat (limited to 'src/core/hle/service/sockets')
| -rw-r--r-- | src/core/hle/service/sockets/sockets_translate.cpp | 16 | ||||
| -rw-r--r-- | src/core/hle/service/sockets/sockets_translate.h | 4 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/core/hle/service/sockets/sockets_translate.cpp b/src/core/hle/service/sockets/sockets_translate.cpp index 139743e1d..2e626fd86 100644 --- a/src/core/hle/service/sockets/sockets_translate.cpp +++ b/src/core/hle/service/sockets/sockets_translate.cpp | |||
| @@ -89,9 +89,9 @@ Network::Protocol Translate(Type type, Protocol protocol) { | |||
| 89 | } | 89 | } |
| 90 | } | 90 | } |
| 91 | 91 | ||
| 92 | u16 TranslatePollEventsToHost(u16 flags) { | 92 | u16 TranslatePollEventsToHost(u32 flags) { |
| 93 | u16 result = 0; | 93 | u32 result = 0; |
| 94 | const auto translate = [&result, &flags](u16 from, u16 to) { | 94 | const auto translate = [&result, &flags](u32 from, u32 to) { |
| 95 | if ((flags & from) != 0) { | 95 | if ((flags & from) != 0) { |
| 96 | flags &= ~from; | 96 | flags &= ~from; |
| 97 | result |= to; | 97 | result |= to; |
| @@ -105,12 +105,12 @@ u16 TranslatePollEventsToHost(u16 flags) { | |||
| 105 | translate(POLL_NVAL, Network::POLL_NVAL); | 105 | translate(POLL_NVAL, Network::POLL_NVAL); |
| 106 | 106 | ||
| 107 | UNIMPLEMENTED_IF_MSG(flags != 0, "Unimplemented flags={}", flags); | 107 | UNIMPLEMENTED_IF_MSG(flags != 0, "Unimplemented flags={}", flags); |
| 108 | return result; | 108 | return static_cast<u16>(result); |
| 109 | } | 109 | } |
| 110 | 110 | ||
| 111 | u16 TranslatePollEventsToGuest(u16 flags) { | 111 | u16 TranslatePollEventsToGuest(u32 flags) { |
| 112 | u16 result = 0; | 112 | u32 result = 0; |
| 113 | const auto translate = [&result, &flags](u16 from, u16 to) { | 113 | const auto translate = [&result, &flags](u32 from, u32 to) { |
| 114 | if ((flags & from) != 0) { | 114 | if ((flags & from) != 0) { |
| 115 | flags &= ~from; | 115 | flags &= ~from; |
| 116 | result |= to; | 116 | result |= to; |
| @@ -125,7 +125,7 @@ u16 TranslatePollEventsToGuest(u16 flags) { | |||
| 125 | translate(Network::POLL_NVAL, POLL_NVAL); | 125 | translate(Network::POLL_NVAL, POLL_NVAL); |
| 126 | 126 | ||
| 127 | UNIMPLEMENTED_IF_MSG(flags != 0, "Unimplemented flags={}", flags); | 127 | UNIMPLEMENTED_IF_MSG(flags != 0, "Unimplemented flags={}", flags); |
| 128 | return result; | 128 | return static_cast<u16>(result); |
| 129 | } | 129 | } |
| 130 | 130 | ||
| 131 | Network::SockAddrIn Translate(SockAddrIn value) { | 131 | Network::SockAddrIn Translate(SockAddrIn value) { |
diff --git a/src/core/hle/service/sockets/sockets_translate.h b/src/core/hle/service/sockets/sockets_translate.h index 8ed041e31..e498913d4 100644 --- a/src/core/hle/service/sockets/sockets_translate.h +++ b/src/core/hle/service/sockets/sockets_translate.h | |||
| @@ -31,10 +31,10 @@ Network::Type Translate(Type type); | |||
| 31 | Network::Protocol Translate(Type type, Protocol protocol); | 31 | Network::Protocol Translate(Type type, Protocol protocol); |
| 32 | 32 | ||
| 33 | /// Translate abstract poll event flags to guest poll event flags | 33 | /// Translate abstract poll event flags to guest poll event flags |
| 34 | u16 TranslatePollEventsToHost(u16 flags); | 34 | u16 TranslatePollEventsToHost(u32 flags); |
| 35 | 35 | ||
| 36 | /// Translate guest poll event flags to abstract poll event flags | 36 | /// Translate guest poll event flags to abstract poll event flags |
| 37 | u16 TranslatePollEventsToGuest(u16 flags); | 37 | u16 TranslatePollEventsToGuest(u32 flags); |
| 38 | 38 | ||
| 39 | /// Translate guest socket address structure to abstract socket address structure | 39 | /// Translate guest socket address structure to abstract socket address structure |
| 40 | Network::SockAddrIn Translate(SockAddrIn value); | 40 | Network::SockAddrIn Translate(SockAddrIn value); |