X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_spanningtree%2Fmain.cpp;h=ea01bb2c52eb7df44730f0e2d0e9d26346ea2380;hb=5b6462f4f60f743ab63480d76d40a40c6b0453d1;hp=d037b7101ccf401b88ec8b24b3678363055b6a34;hpb=f7464bb04218629fc326e506949c7d66ab6c31f4;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_spanningtree/main.cpp b/src/modules/m_spanningtree/main.cpp index d037b7101..ea01bb2c5 100644 --- a/src/modules/m_spanningtree/main.cpp +++ b/src/modules/m_spanningtree/main.cpp @@ -13,6 +13,7 @@ /* $ModDesc: Provides a spanning tree server link protocol */ +#include "inspircd.h" #include "configreader.h" #include "users.h" #include "channels.h" @@ -20,7 +21,6 @@ #include "commands/cmd_whois.h" #include "commands/cmd_stats.h" #include "socket.h" -#include "inspircd.h" #include "wildcard.h" #include "xline.h" #include "transport.h" @@ -37,7 +37,7 @@ /* $ModDep: m_spanningtree/timesynctimer.h m_spanningtree/resolvers.h m_spanningtree/main.h m_spanningtree/utils.h m_spanningtree/treeserver.h m_spanningtree/link.h m_spanningtree/treesocket.h m_spanningtree/rconnect.h */ ModuleSpanningTree::ModuleSpanningTree(InspIRCd* Me) - : Module::Module(Me), max_local(0), max_global(0) + : Module(Me), max_local(0), max_global(0) { ServerInstance->UseInterface("InspSocketHook"); Utils = new SpanningTreeUtilities(Me, this); @@ -907,8 +907,7 @@ void ModuleSpanningTree::OnUserJoin(userrec* user, chanrec* channel, bool &silen Utils->DoOneToMany(ServerInstance->Config->ServerName,"FJOIN",params); /* First user in, sync the modes for the channel */ params.pop_back(); - /* This is safe, all inspircd servers default to +nt */ - params.push_back("+nt"); + params.push_back(channel->ChanModes(true)); Utils->DoOneToMany(ServerInstance->Config->ServerName,"FMODE",params); } else @@ -1379,7 +1378,7 @@ class ModuleSpanningTreeFactory : public ModuleFactory }; -extern "C" void * init_module( void ) +extern "C" DllExport void * init_module( void ) { return new ModuleSpanningTreeFactory; }