summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2018-08-19 22:34:10 +0200
committerMax Kellermann <max@musicpd.org>2018-08-19 22:34:10 +0200
commit3caef29b93a6f52dde1e6b565c967bf0fb612654 (patch)
tree02c2455e42dcdcf39abfd799ba8fe5f3697d037c /test
parent5f95c073057695acfcdea4f1ffed7610304d31e2 (diff)
test/DumpDatabase: allocate ConfigData on the stack
Diffstat (limited to 'test')
-rw-r--r--test/DumpDatabase.cxx11
1 files changed, 5 insertions, 6 deletions
diff --git a/test/DumpDatabase.cxx b/test/DumpDatabase.cxx
index 671af4922..f1fb864c1 100644
--- a/test/DumpDatabase.cxx
+++ b/test/DumpDatabase.cxx
@@ -26,7 +26,8 @@
#include "db/LightDirectory.hxx"
#include "song/LightSong.hxx"
#include "db/PlaylistVector.hxx"
-#include "config/Global.hxx"
+#include "config/File.hxx"
+#include "config/Migrate.hxx"
#include "config/Data.hxx"
#include "config/Param.hxx"
#include "config/Block.hxx"
@@ -50,11 +51,9 @@ class GlobalInit {
public:
GlobalInit() {
io_thread.Start();
- config_global_init();
}
~GlobalInit() {
- config_global_finish();
}
EventLoop &GetEventLoop() {
@@ -125,9 +124,9 @@ try {
GlobalInit init;
- ReadConfigFile(config_path);
-
- const auto &config = GetGlobalConfig();
+ ConfigData config;
+ ReadConfigFile(config, config_path);
+ Migrate(config);
TagLoadConfig(config);