diff options
author | Bastien Bouclet | 2020-01-01 08:19:48 +0100 |
---|---|---|
committer | Bastien Bouclet | 2020-01-01 08:19:48 +0100 |
commit | 94543467822401b407f4b061268e42d59d6a905b (patch) | |
tree | 09220358172e1e665c66d97e57c368381bab9261 /engines/game.h | |
parent | 13e0ea0ad47e2863b6e1fa319042507b762621a3 (diff) | |
download | scummvm-rg350-94543467822401b407f4b061268e42d59d6a905b.tar.gz scummvm-rg350-94543467822401b407f4b061268e42d59d6a905b.tar.bz2 scummvm-rg350-94543467822401b407f4b061268e42d59d6a905b.zip |
ENGINES: Copy the data referenced by QualifiedGameDescriptor
The engineId, gameId and description come from static data in the game
engines. When the game engines are compiled as dynamic plugins, the QGD
structure may outlive the engine plugin. Making a copy ensures the data
remains available.
Fixes #11292.
Diffstat (limited to 'engines/game.h')
-rw-r--r-- | engines/game.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/engines/game.h b/engines/game.h index e378976cb1..8316857e24 100644 --- a/engines/game.h +++ b/engines/game.h @@ -66,10 +66,12 @@ public: /** * The description of a game supported by an engine */ -struct QualifiedGameDescriptor : public PlainGameDescriptor { - const char *engineId; +struct QualifiedGameDescriptor { + Common::String engineId; + Common::String gameId; + Common::String description; - QualifiedGameDescriptor(); + QualifiedGameDescriptor() {} QualifiedGameDescriptor(const char *engine, const PlainGameDescriptor &pgd); }; |