aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_spanningtree/capab.cpp2
-rw-r--r--src/modules/m_spanningtree/main.h7
-rw-r--r--src/modules/m_spanningtree/treesocket.h2
3 files changed, 7 insertions, 4 deletions
diff --git a/src/modules/m_spanningtree/capab.cpp b/src/modules/m_spanningtree/capab.cpp
index 18f25b2c6..ef0e16d2d 100644
--- a/src/modules/m_spanningtree/capab.cpp
+++ b/src/modules/m_spanningtree/capab.cpp
@@ -238,7 +238,7 @@ bool TreeSocket::Capab(const CommandBase::Params& params)
capab->OptModuleList.clear();
capab->CapKeys.clear();
if (params.size() > 1)
- proto_version = ConvToNum<unsigned int>(params[1]);
+ proto_version = ConvToNum<uint16_t>(params[1]);
if (proto_version < PROTO_OLDEST)
{
diff --git a/src/modules/m_spanningtree/main.h b/src/modules/m_spanningtree/main.h
index aa8623e0f..9a582bf49 100644
--- a/src/modules/m_spanningtree/main.h
+++ b/src/modules/m_spanningtree/main.h
@@ -45,16 +45,19 @@
* If you introduce new protocol versions please document them here:
* https://docs.inspircd.org/spanningtree/changes
*/
-enum ProtocolVersion
+enum ProtocolVersion : uint16_t
{
/** The linking protocol version introduced in InspIRCd v3.0. */
PROTO_INSPIRCD_30 = 1205,
+ /** The linking protocol version introduced in InspIRCd v4.0a1. */
+ PROTO_INSPIRCD_40_A1 = 1206,
+
/** The oldest version of the protocol that we support. */
PROTO_OLDEST = PROTO_INSPIRCD_30,
/** The newest version of the protocol that we support. */
- PROTO_NEWEST = PROTO_INSPIRCD_30
+ PROTO_NEWEST = PROTO_INSPIRCD_40_A1
};
/** Forward declarations
diff --git a/src/modules/m_spanningtree/treesocket.h b/src/modules/m_spanningtree/treesocket.h
index 925afac2e..bc08183af 100644
--- a/src/modules/m_spanningtree/treesocket.h
+++ b/src/modules/m_spanningtree/treesocket.h
@@ -112,7 +112,7 @@ class TreeSocket : public BufferedSocket
TreeServer* MyRoot = NULL;
/* Remote protocol version */
- unsigned int proto_version = 0;
+ uint16_t proto_version = 0;
/** Checks if the given servername and sid are both free
*/