diff options
| author | 2015-02-11 17:04:26 +0100 | |
|---|---|---|
| committer | 2015-02-11 17:04:26 +0100 | |
| commit | c19e9d0edbb1be9d5fd6f281bce054066fc4a003 (patch) | |
| tree | b461dadef2c80424176ce0b6a51ff7451f2ac792 /src/modules/m_sasl.cpp | |
| parent | Convert the CAP event to use the new cross-module event system (diff) | |
| download | inspircd++-c19e9d0edbb1be9d5fd6f281bce054066fc4a003.tar.gz inspircd++-c19e9d0edbb1be9d5fd6f281bce054066fc4a003.tar.bz2 inspircd++-c19e9d0edbb1be9d5fd6f281bce054066fc4a003.zip | |
Convert the SASL fallback event to use the new cross-module event system
Diffstat (limited to 'src/modules/m_sasl.cpp')
| -rw-r--r-- | src/modules/m_sasl.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/modules/m_sasl.cpp b/src/modules/m_sasl.cpp index ade998b4e..c96b87034 100644 --- a/src/modules/m_sasl.cpp +++ b/src/modules/m_sasl.cpp @@ -28,12 +28,13 @@ enum SaslState { SASL_INIT, SASL_COMM, SASL_DONE }; enum SaslResult { SASL_OK, SASL_FAIL, SASL_ABORT }; static std::string sasl_target = "*"; +static Events::ModuleEventProvider* saslevprov; static void SendSASL(const parameterlist& params) { if (!ServerInstance->PI->SendEncapsulatedData(sasl_target, "SASL", params)) { - SASLFallback(NULL, params); + FOREACH_MOD_CUSTOM(*saslevprov, SASLEventListener, OnSASLAuth, (params)); } } @@ -246,6 +247,7 @@ class ModuleSASL : public Module GenericCap cap; CommandAuthenticate auth; CommandSASL sasl; + Events::ModuleEventProvider sasleventprov; public: ModuleSASL() @@ -253,7 +255,9 @@ class ModuleSASL : public Module , cap(this, "sasl") , auth(this, authExt, cap) , sasl(this, authExt) + , sasleventprov(this, "event/sasl") { + saslevprov = &sasleventprov; } void init() CXX11_OVERRIDE |
