summaryrefslogtreecommitdiff
path: root/src/siphash.cpp
diff options
context:
space:
mode:
authorSadie Powell <sadie@witchery.services>2022-01-03 19:17:02 +0000
committerSadie Powell <sadie@witchery.services>2022-01-04 00:39:05 +0000
commiteb81f22a5b1df18c9844893c55f57762148f2bd0 (patch)
treefb178d90cac536562faeabd2a57f720d70cc0530 /src/siphash.cpp
parenta31a7f5a6ce3f47716a9313d232c2a40955fd1e1 (diff)
Modernize CXXFLAGS on Unix and enable -Werror on CI.
Also clear up warnings that this exposed.
Diffstat (limited to 'src/siphash.cpp')
-rw-r--r--src/siphash.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/siphash.cpp b/src/siphash.cpp
index 612b6eec7..9460f085b 100644
--- a/src/siphash.cpp
+++ b/src/siphash.cpp
@@ -120,12 +120,12 @@ uint64_t Anope::SipHash24(const void *src, unsigned long src_sz, const char key[
uint64_t t = 0; uint8_t *pt = (uint8_t *)&t; uint8_t *m = (uint8_t *)in;
switch (src_sz)
{
- case 7: pt[6] = m[6];
- case 6: pt[5] = m[5];
- case 5: pt[4] = m[4];
+ case 7: pt[6] = m[6]; [[fallthrough]];
+ case 6: pt[5] = m[5]; [[fallthrough]];
+ case 5: pt[4] = m[4]; [[fallthrough]];
case 4: *((uint32_t*)&pt[0]) = *((uint32_t*)&m[0]); break;
- case 3: pt[2] = m[2];
- case 2: pt[1] = m[1];
+ case 3: pt[2] = m[2]; [[fallthrough]];
+ case 2: pt[1] = m[1]; [[fallthrough]];
case 1: pt[0] = m[0];
}
b |= _le64toh(t);