diff --git a/src/ConfigData.cxx b/src/ConfigData.cxx index 27a72eb8b..7ac517935 100644 --- a/src/ConfigData.cxx +++ b/src/ConfigData.cxx @@ -131,53 +131,3 @@ config_param::GetBlockValue(const char *name, bool default_value) const return bp->GetBoolValue(); } - -const char * -config_get_block_string(const struct config_param *param, const char *name, - const char *default_value) -{ - if (param == nullptr) - return default_value; - - return param->GetBlockValue(name, default_value); -} - -char * -config_dup_block_string(const struct config_param *param, const char *name, - const char *default_value) -{ - return g_strdup(config_get_block_string(param, name, default_value)); -} - -char * -config_dup_block_path(const struct config_param *param, const char *name, - GError **error_r) -{ - assert(error_r != NULL); - assert(*error_r == NULL); - - if (param == nullptr) - return nullptr; - - return param->DupBlockPath(name, error_r); -} - -unsigned -config_get_block_unsigned(const struct config_param *param, const char *name, - unsigned default_value) -{ - if (param == nullptr) - return default_value; - - return param->GetBlockValue(name, default_value); -} - -bool -config_get_block_bool(const struct config_param *param, const char *name, - bool default_value) -{ - if (param == nullptr) - return default_value; - - return param->GetBlockValue(name, default_value); -} diff --git a/src/ConfigData.hxx b/src/ConfigData.hxx index d6b024b9b..2586ed4b2 100644 --- a/src/ConfigData.hxx +++ b/src/ConfigData.hxx @@ -124,33 +124,4 @@ struct ConfigData { std::array params; }; -gcc_pure -const char * -config_get_block_string(const struct config_param *param, const char *name, - const char *default_value); - -gcc_malloc -char * -config_dup_block_string(const struct config_param *param, const char *name, - const char *default_value); - -/** - * Same as config_dup_path(), but looks up the setting in the - * specified block. - */ -gcc_malloc -char * -config_dup_block_path(const struct config_param *param, const char *name, - GError **error_r); - -gcc_pure -unsigned -config_get_block_unsigned(const struct config_param *param, const char *name, - unsigned default_value); - -gcc_pure -bool -config_get_block_bool(const struct config_param *param, const char *name, - bool default_value); - #endif