X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_sslmodes.cpp;h=d3afd00e6854ca4fac1adaf74736889904929ab9;hb=52727673077afcb7377cef7491d3bdf9ab1c372e;hp=1a596f5e0424b0332b344566e965ef9011132425;hpb=f62654a6859998f9d63eb22702c572d5ebcff15c;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_sslmodes.cpp b/src/modules/m_sslmodes.cpp index 1a596f5e0..d3afd00e6 100644 --- a/src/modules/m_sslmodes.cpp +++ b/src/modules/m_sslmodes.cpp @@ -24,6 +24,12 @@ #include "inspircd.h" #include "modules/ssl.h" +enum +{ + // From UnrealIRCd. + ERR_SECUREONLYCHAN = 489 +}; + /** Handle channel mode +z */ class SSLMode : public ModeHandler @@ -54,7 +60,7 @@ class SSLMode : public ModeHandler ssl_cert* cert = API->GetCertificate(i->first); if (!cert && !i->first->server->IsULine()) { - source->WriteNumeric(ERR_ALLMUSTSSL, "%s :all members of the channel must be connected via SSL", channel->name.c_str()); + source->WriteNumeric(ERR_ALLMUSTSSL, channel->name, "all members of the channel must be connected via SSL"); return MODEACTION_DENY; } } @@ -107,7 +113,7 @@ class ModuleSSLModes : public Module else { // Deny - user->WriteNumeric(489, "%s :Cannot join channel; SSL users only (+z)", cname.c_str()); + user->WriteNumeric(ERR_SECUREONLYCHAN, cname, "Cannot join channel; SSL users only (+z)"); return MOD_RES_DENY; } }