From a9031b6bae742b333b1b390192fa590f2ecb07ea Mon Sep 17 00:00:00 2001 From: peterbell10 Date: Mon, 5 Oct 2020 11:27:14 +0100 Subject: Fix cmake not adding Werror on clang, and _lots_ of warnings (#4963) * Fix cmake not adding Werror on clang, and _lots_ of warnings * WIP: Build fixes * Cannot make intermediate blockhandler instance * Tiger's changes * Fix BitIndex check * Handle invalid NextState values in cMultiVersionProtocol Co-authored-by: Tiger Wang --- src/Protocol/ChunkDataSerializer.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Protocol/ChunkDataSerializer.h') diff --git a/src/Protocol/ChunkDataSerializer.h b/src/Protocol/ChunkDataSerializer.h index cb39e27d6..aeff7c356 100644 --- a/src/Protocol/ChunkDataSerializer.h +++ b/src/Protocol/ChunkDataSerializer.h @@ -31,7 +31,7 @@ class cChunkDataSerializer v401, v477, - Count + Last = CacheVersion::v477 }; /** A single cache entry containing the raw data, compressed data, and a validity flag. */ @@ -79,7 +79,7 @@ protected: /** A cache, mapping protocol version to a fully serialised chunk. It is used during a single invocation of SendToClients with more than one client. */ - std::array(CacheVersion::Count)> m_Cache; + std::array(CacheVersion::Last) + 1> m_Cache; } ; -- cgit v1.2.3