diff options
| author | 2014-03-06 21:43:36 +0000 | |
|---|---|---|
| committer | 2014-03-08 13:01:09 +0100 | |
| commit | f2db4b743f0df9b9e588979fd0fcf2815e54af44 (patch) | |
| tree | aaef011a92d187cb1e7a81355de18e2f58d8815e /src/modules/m_spanningtree/utils.cpp | |
| parent | Fix m_permchannels not prepending the path when reading the config. (diff) | |
| download | inspircd++-f2db4b743f0df9b9e588979fd0fcf2815e54af44.tar.gz inspircd++-f2db4b743f0df9b9e588979fd0fcf2815e54af44.tar.bz2 inspircd++-f2db4b743f0df9b9e588979fd0fcf2815e54af44.zip | |
Make the maximum hostname length configurable in the config.
Diffstat (limited to 'src/modules/m_spanningtree/utils.cpp')
| -rw-r--r-- | src/modules/m_spanningtree/utils.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/utils.cpp b/src/modules/m_spanningtree/utils.cpp index de96b073d..263a5db1e 100644 --- a/src/modules/m_spanningtree/utils.cpp +++ b/src/modules/m_spanningtree/utils.cpp @@ -301,8 +301,8 @@ void SpanningTreeUtilities::ReadConfiguration() if (L->Name.find('.') == std::string::npos) throw ModuleException("The link name '"+assign(L->Name)+"' is invalid as it must contain at least one '.' character"); - if (L->Name.length() > 64) - throw ModuleException("The link name '"+assign(L->Name)+"' is invalid as it is longer than 64 characters"); + if (L->Name.length() > ServerInstance->Config->Limits.MaxHost) + throw ModuleException("The link name '"+assign(L->Name)+"' is invalid as it is longer than " + ConvToStr(ServerInstance->Config->Limits.MaxHost) + " characters"); if (L->RecvPass.empty()) throw ModuleException("Invalid configuration for server '"+assign(L->Name)+"', recvpass not defined"); |
