From 67b45186a572fb051e73fd88d4fc580a0d4d2f6b Mon Sep 17 00:00:00 2001 From: Michael Brown Date: Wed, 1 Dec 2010 16:34:23 +0000 Subject: [settings] Apply settings block name in register_settings() Pass the settings block name as a parameter to register_settings(), rather than defining it with settings_init() (and then possibly changing it by directly manipulating settings->name). Signed-off-by: Michael Brown --- src/interface/smbios/smbios_settings.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/interface') diff --git a/src/interface/smbios/smbios_settings.c b/src/interface/smbios/smbios_settings.c index 09e1a5786..bb7c18dd8 100644 --- a/src/interface/smbios/smbios_settings.c +++ b/src/interface/smbios/smbios_settings.c @@ -125,7 +125,6 @@ static struct settings_operations smbios_settings_operations = { /** SMBIOS settings */ static struct settings smbios_settings = { .refcnt = NULL, - .name = "smbios", .tag_magic = SMBIOS_EMPTY_TAG, .siblings = LIST_HEAD_INIT ( smbios_settings.siblings ), .children = LIST_HEAD_INIT ( smbios_settings.children ), @@ -136,7 +135,8 @@ static struct settings smbios_settings = { static void smbios_init ( void ) { int rc; - if ( ( rc = register_settings ( &smbios_settings, NULL ) ) != 0 ) { + if ( ( rc = register_settings ( &smbios_settings, NULL, + "smbios" ) ) != 0 ) { DBG ( "SMBIOS could not register settings: %s\n", strerror ( rc ) ); return; -- cgit v1.2.3-55-g7522