Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Alexander_Naumov:SLE12
openlmi-providers
0003-Run-dmidecode-with-full-path.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0003-Run-dmidecode-with-full-path.patch of Package openlmi-providers
From 496f46fd37e189e08721b2b7297510d9e071dc11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Klaus=20K=C3=A4mpf?= <kkaempf@suse.de> Date: Thu, 17 Oct 2013 14:55:40 +0200 Subject: [PATCH 3/7] Run dmidecode with full path --- src/hardware/dmidecode.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/hardware/dmidecode.c b/src/hardware/dmidecode.c index c241ceaef91d..1e262adaf82e 100644 --- a/src/hardware/dmidecode.c +++ b/src/hardware/dmidecode.c @@ -149,7 +149,7 @@ short dmi_get_processors(DmiProcessor **cpus, unsigned *cpus_nb) dmi_free_processors(cpus, cpus_nb); /* get dmidecode output */ - if (run_command("dmidecode -t 4", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 4", &buffer, &buffer_size) != 0) { goto done; } @@ -521,7 +521,7 @@ short dmi_get_cpu_caches(DmiCpuCache **caches, unsigned *caches_nb) dmi_free_cpu_caches(caches, caches_nb); /* get dmidecode output */ - if (run_command("dmidecode -t 7", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 7", &buffer, &buffer_size) != 0) { goto done; } @@ -812,7 +812,7 @@ short dmi_get_memory(DmiMemory *memory) init_dmi_memory_struct(memory); /* get dmidecode output for memory modules */ - if (run_command("dmidecode -t 17", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 17", &buffer, &buffer_size) != 0) { goto done; } @@ -979,7 +979,7 @@ short dmi_get_memory(DmiMemory *memory) free_2d_buffer(&buffer, &buffer_size); /* get additional dmidecode output for memory modules */ - if (run_command("dmidecode -t 6", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 6", &buffer, &buffer_size) != 0) { goto done; } @@ -1036,7 +1036,7 @@ short dmi_get_memory(DmiMemory *memory) free_2d_buffer(&buffer, &buffer_size); /* get dmidecode output for memory array */ - if (run_command("dmidecode -t 19", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 19", &buffer, &buffer_size) != 0) { goto done; } @@ -1225,7 +1225,7 @@ short dmi_get_chassis(DmiChassis *chassis) init_dmi_chassis_struct(chassis); /* get dmidecode output for chassis */ - if (run_command("dmidecode -t 3", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 3", &buffer, &buffer_size) != 0) { goto done; } @@ -1304,7 +1304,7 @@ short dmi_get_chassis(DmiChassis *chassis) free_2d_buffer(&buffer, &buffer_size); /* get additional dmidecode output for chassis */ - if (run_command("dmidecode -t 1", &buffer, &buffer_size) == 0 + if (run_command("/usr/sbin/dmidecode -t 1", &buffer, &buffer_size) == 0 && buffer_size > 4) { for (i = 0; i < buffer_size; i++) { /* Model */ @@ -1457,7 +1457,7 @@ short dmi_get_baseboard(DmiBaseboard *baseboard) init_dmi_baseboard_struct(baseboard); /* get dmidecode output for baseboard */ - if (run_command("dmidecode -t 2", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 2", &buffer, &buffer_size) != 0) { goto done; } @@ -1593,7 +1593,7 @@ short dmi_get_ports(DmiPort **ports, unsigned *ports_nb) dmi_free_ports(ports, ports_nb); /* get dmidecode output */ - if (run_command("dmidecode -t 8", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 8", &buffer, &buffer_size) != 0) { goto done; } @@ -1755,7 +1755,7 @@ short dmi_get_system_slots(DmiSystemSlot **slots, unsigned *slots_nb) dmi_free_system_slots(slots, slots_nb); /* get dmidecode output */ - if (run_command("dmidecode -t 9", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 9", &buffer, &buffer_size) != 0) { goto done; } @@ -1943,7 +1943,7 @@ short dmi_get_pointing_devices(DmiPointingDevice **devices, unsigned *devices_nb dmi_free_pointing_devices(devices, devices_nb); /* get dmidecode output */ - if (run_command("dmidecode -t 21", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 21", &buffer, &buffer_size) != 0) { goto done; } @@ -2118,7 +2118,7 @@ short dmi_get_batteries(DmiBattery **batteries, unsigned *batteries_nb) dmi_free_batteries(batteries, batteries_nb); /* get dmidecode output */ - if (run_command("dmidecode -t 22", &buffer, &buffer_size) != 0) { + if (run_command("/usr/sbin/dmidecode -t 22", &buffer, &buffer_size) != 0) { goto done; } -- 1.8.4
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor