From ad57a3f7fe910cf509485e8b394007ce397df0ad Mon Sep 17 00:00:00 2001 From: Burt P Date: Sat, 13 Oct 2018 17:09:19 -0500 Subject: Allow DMI on non-x86 There's nothing preventing this from running on non-x86. If it is not available it will just say so, like PCI. Signed-off-by: Burt P --- modules/devices/dmi.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'modules/devices') diff --git a/modules/devices/dmi.c b/modules/devices/dmi.c index 31b0c43d..0f8af169 100644 --- a/modules/devices/dmi.c +++ b/modules/devices/dmi.c @@ -153,8 +153,11 @@ void __scan_dmi() dmi_ok = dmi_get_info(); if (!dmi_ok) { - dmi_info = g_strdup("[No DMI information]\n" - "There was an error retrieving the information.=\n" - "Please try running HardInfo as root.=\n"); + dmi_info = g_strdup_printf("[%s]\n%s=\n", + _("DMI Unavailable"), + (getuid() == 0) + ? _("DMI is not avaliable. Perhaps this platform does not provide DMI.") + : _("DMI is not available; Perhaps try running HardInfo as root.") ); + } } -- cgit v1.2.3