diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-06-24 16:27:16 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-06-24 16:27:16 +0000 |
commit | 8a3bcebffc063457b0e49f87ac5d80d18994e3f0 (patch) | |
tree | 88a889e86186234d5f8242889d5fe56dcb4643de | |
parent | 999f4d2f143bf730f0e346921a8fa687936a79cf (diff) |
This is more correct, thanks Phoenix
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9932 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | src/modules/extra/m_ssl_gnutls.cpp | 5 | ||||
-rw-r--r-- | src/modules/extra/m_ssl_openssl.cpp | 5 |
2 files changed, 4 insertions, 6 deletions
diff --git a/src/modules/extra/m_ssl_gnutls.cpp b/src/modules/extra/m_ssl_gnutls.cpp index fb50c0f09..9d9e08d4c 100644 --- a/src/modules/extra/m_ssl_gnutls.cpp +++ b/src/modules/extra/m_ssl_gnutls.cpp @@ -293,11 +293,12 @@ class ModuleSSLGnuTLS : public Module { User* user = (User*)item; - if(user->io) + if (user->io == this) { // User is using SSL, they're a local user, and they're using one of *our* SSL ports. // Potentially there could be multiple SSL modules loaded at once on different ports. ServerInstance->Users->QuitUser(user, "SSL module unloading"); + user->io = NULL; } if (user->GetExt("ssl_cert", dummy)) { @@ -306,8 +307,6 @@ class ModuleSSLGnuTLS : public Module delete tofree; user->Shrink("ssl_cert"); } - - user->io = NULL; } } diff --git a/src/modules/extra/m_ssl_openssl.cpp b/src/modules/extra/m_ssl_openssl.cpp index 4368c8d47..83ae36e73 100644 --- a/src/modules/extra/m_ssl_openssl.cpp +++ b/src/modules/extra/m_ssl_openssl.cpp @@ -318,11 +318,12 @@ class ModuleSSLOpenSSL : public Module { User* user = (User*)item; - if (user->GetExt("ssl", dummy) && IS_LOCAL(user) && user->io == this) + if (user->io == this) { // User is using SSL, they're a local user, and they're using one of *our* SSL ports. // Potentially there could be multiple SSL modules loaded at once on different ports. ServerInstance->Users->QuitUser(user, "SSL module unloading"); + user->io = NULL; } if (user->GetExt("ssl_cert", dummy)) { @@ -331,8 +332,6 @@ class ModuleSSLOpenSSL : public Module delete tofree; user->Shrink("ssl_cert"); } - - user->io = NULL; } } |