diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-07 20:48:13 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-07 20:48:13 +0000 |
commit | 18f04c60d59085ad768f149c8e9e4b650b8dc717 (patch) | |
tree | 32427f9d92f86733d03ad09650d26ebec6702fad /src/modules | |
parent | 766ef68519f7fc333476baf8a6d8914af9024612 (diff) |
Added OnUserQuit stuffs
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2257 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_swhois.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/modules/m_swhois.cpp b/src/modules/m_swhois.cpp index 3b150cd7d..01aaa3915 100644 --- a/src/modules/m_swhois.cpp +++ b/src/modules/m_swhois.cpp @@ -94,6 +94,18 @@ class ModuleSWhois : public Module } } + // when a user quits, tidy up their metadata + virtual void OnUserQuit(userrec* user, std::string message) + { + char* field = user->GetExt("swhois"); + if (field) + { + std::string* swhois = (std::string*)field; + user->Shrink("swhois"); + delete swhois; + } + } + // Whenever the linking module receives metadata from another server and doesnt know what // to do with it (of course, hence the 'meta') it calls this method, and it is up to each // module in turn to figure out if this metadata key belongs to them, and what they want |