summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2008-04-21 16:59:23 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2008-04-21 16:59:23 +0000
commit98659aa0dcac7636627846555ef7d5f807152b7e (patch)
tree4726b3771ad6874862f2ff7b503264eed617f8d4 /include
parentf21617328a8a576c8ada619f2934ac31f0dec717 (diff)
Merge in large patchset from GreenReaper, useful fixes for freeing a ton of different things on shutdown for tidyness, and a few stack corruption fixes in the mode handler
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9565 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include')
-rw-r--r--include/ctables.h5
-rw-r--r--include/usermanager.h10
2 files changed, 13 insertions, 2 deletions
diff --git a/include/ctables.h b/include/ctables.h
index fa0d42d74..ba6773a4c 100644
--- a/include/ctables.h
+++ b/include/ctables.h
@@ -167,7 +167,10 @@ class CoreExport Command : public Extensible
/** Standard constructor gubbins
*/
- virtual ~Command() {}
+ virtual ~Command()
+ {
+ syntax.clear();
+ }
};
/** A hash of commands used by the core
diff --git a/include/usermanager.h b/include/usermanager.h
index 4c50c4292..3a9e15150 100644
--- a/include/usermanager.h
+++ b/include/usermanager.h
@@ -32,7 +32,15 @@ class CoreExport UserManager : public classbase
{
ServerInstance = Instance;
}
-
+
+ ~UserManager()
+ {
+ for (user_hash::iterator i = clientlist->begin();i != clientlist->end();i++)
+ {
+ delete i->second;
+ }
+ clientlist->clear();
+ }
/** Client list, a hash_map containing all clients, local and remote
*/