From 3a4a430f6ca3e3afb7e94b5f5738e1862b8b5222 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 17 Jul 2018 23:09:56 +0200 Subject: fs/Config: use struct ConfigData --- src/fs/Config.cxx | 8 +++++--- src/fs/Config.hxx | 4 +++- 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'src/fs') diff --git a/src/fs/Config.cxx b/src/fs/Config.cxx index 9d51da47e..140e3becd 100644 --- a/src/fs/Config.cxx +++ b/src/fs/Config.cxx @@ -20,15 +20,17 @@ #include "config.h" #include "Config.hxx" #include "Charset.hxx" -#include "config/Global.hxx" +#include "config/Data.hxx" void -ConfigureFS() +ConfigureFS(const ConfigData &config) { #ifdef HAVE_FS_CHARSET - const char *charset = config_get_string(ConfigOption::FS_CHARSET); + const char *charset = config.GetString(ConfigOption::FS_CHARSET); if (charset != nullptr) SetFSCharset(charset); +#else + (void)config; #endif } diff --git a/src/fs/Config.hxx b/src/fs/Config.hxx index cd03e0ff7..fdc7453a6 100644 --- a/src/fs/Config.hxx +++ b/src/fs/Config.hxx @@ -22,13 +22,15 @@ #include "check.h" +struct ConfigData; + /** * Performs global one-time initialization of this class. * * Throws std::runtime_error on error. */ void -ConfigureFS(); +ConfigureFS(const ConfigData &config); void DeinitFS(); -- cgit v1.2.3