From 1992ce920eb5268be9487b3bba6d28353d871111 Mon Sep 17 00:00:00 2001 From: Thorbjørn Lindeijer Date: Mon, 15 May 2023 16:09:09 +0200 Subject: Manage CharacterData using std::unique_ptr Fixes many memory leaks, but also made it clear that we're very often loading all the character data only to immediately throw it away again, even when most of the time all we really need is the database ID or the name. --- src/account-server/character.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/account-server/character.h') diff --git a/src/account-server/character.h b/src/account-server/character.h index e3c1b49c..d17fc9d1 100644 --- a/src/account-server/character.h +++ b/src/account-server/character.h @@ -21,6 +21,7 @@ #ifndef CHARACTERDATA_H #define CHARACTERDATA_H +#include #include #include #include @@ -277,6 +278,6 @@ class CharacterData /** * Type definition for a list of Characters. */ -using Characters = std::map; +using Characters = std::map>; #endif -- cgit v1.2.3-70-g09d2