diff --git a/src/config/Block.cxx b/src/config/Block.cxx index dc9b5c070..1602ef402 100644 --- a/src/config/Block.cxx +++ b/src/config/Block.cxx @@ -91,8 +91,8 @@ ConfigBlock::GetBlockValue(const char *name, const char *default_value) const } AllocatedPath -ConfigBlock::GetBlockPath(const char *name, const char *default_value, - Error &error) const +ConfigBlock::GetPath(const char *name, const char *default_value, + Error &error) const { assert(!error.IsDefined()); @@ -119,9 +119,9 @@ ConfigBlock::GetBlockPath(const char *name, const char *default_value, } AllocatedPath -ConfigBlock::GetBlockPath(const char *name, Error &error) const +ConfigBlock::GetPath(const char *name, Error &error) const { - return GetBlockPath(name, nullptr, error); + return GetPath(name, nullptr, error); } int diff --git a/src/config/Block.hxx b/src/config/Block.hxx index e0d8a09e5..5cf2b258f 100644 --- a/src/config/Block.hxx +++ b/src/config/Block.hxx @@ -112,10 +112,10 @@ struct ConfigBlock { * Same as config_get_path(), but looks up the setting in the * specified block. */ - AllocatedPath GetBlockPath(const char *name, const char *default_value, - Error &error) const; + AllocatedPath GetPath(const char *name, const char *default_value, + Error &error) const; - AllocatedPath GetBlockPath(const char *name, Error &error) const; + AllocatedPath GetPath(const char *name, Error &error) const; gcc_pure int GetBlockValue(const char *name, int default_value) const; diff --git a/src/db/plugins/simple/SimpleDatabasePlugin.cxx b/src/db/plugins/simple/SimpleDatabasePlugin.cxx index 84328b998..6c0b27ad8 100644 --- a/src/db/plugins/simple/SimpleDatabasePlugin.cxx +++ b/src/db/plugins/simple/SimpleDatabasePlugin.cxx @@ -92,7 +92,7 @@ SimpleDatabase::Create(gcc_unused EventLoop &loop, bool SimpleDatabase::Configure(const ConfigBlock &block, Error &error) { - path = block.GetBlockPath("path", error); + path = block.GetPath("path", error); if (path.IsNull()) { if (!error.IsDefined()) error.Set(simple_db_domain, @@ -102,7 +102,7 @@ SimpleDatabase::Configure(const ConfigBlock &block, Error &error) path_utf8 = path.ToUTF8(); - cache_path = block.GetBlockPath("cache_directory", error); + cache_path = block.GetPath("cache_directory", error); if (path.IsNull() && error.IsDefined()) return false; diff --git a/src/decoder/plugins/SidplayDecoderPlugin.cxx b/src/decoder/plugins/SidplayDecoderPlugin.cxx index 6b24aaa4e..ee77d202f 100644 --- a/src/decoder/plugins/SidplayDecoderPlugin.cxx +++ b/src/decoder/plugins/SidplayDecoderPlugin.cxx @@ -86,7 +86,7 @@ sidplay_init(const ConfigBlock &block) { /* read the songlengths database file */ Error error; - const auto database_path = block.GetBlockPath("songlength_database", error); + const auto database_path = block.GetPath("songlength_database", error); if (!database_path.IsNull()) songlength_database = sidplay_load_songlength_db(database_path); else if (error.IsDefined()) diff --git a/src/decoder/plugins/WildmidiDecoderPlugin.cxx b/src/decoder/plugins/WildmidiDecoderPlugin.cxx index bc135485a..e1689e625 100644 --- a/src/decoder/plugins/WildmidiDecoderPlugin.cxx +++ b/src/decoder/plugins/WildmidiDecoderPlugin.cxx @@ -42,9 +42,9 @@ wildmidi_init(const ConfigBlock &block) { Error error; const AllocatedPath path = - block.GetBlockPath("config_file", - "/etc/timidity/timidity.cfg", - error); + block.GetPath("config_file", + "/etc/timidity/timidity.cfg", + error); if (path.IsNull()) FatalError(error); diff --git a/src/output/plugins/FifoOutputPlugin.cxx b/src/output/plugins/FifoOutputPlugin.cxx index 79e9f2349..b9e3b0ce9 100644 --- a/src/output/plugins/FifoOutputPlugin.cxx +++ b/src/output/plugins/FifoOutputPlugin.cxx @@ -183,7 +183,7 @@ FifoOutput::Create(const ConfigBlock &block, Error &error) { FifoOutput *fd = new FifoOutput(); - fd->path = block.GetBlockPath("path", error); + fd->path = block.GetPath("path", error); if (fd->path.IsNull()) { delete fd; diff --git a/src/output/plugins/RecorderOutputPlugin.cxx b/src/output/plugins/RecorderOutputPlugin.cxx index 6cf3af624..74ada8c7c 100644 --- a/src/output/plugins/RecorderOutputPlugin.cxx +++ b/src/output/plugins/RecorderOutputPlugin.cxx @@ -128,7 +128,7 @@ RecorderOutput::Configure(const ConfigBlock &block, Error &error) return false; } - path = block.GetBlockPath("path", error); + path = block.GetPath("path", error); if (error.IsDefined()) return false;