diff options
Diffstat (limited to 'hardinfo2/arch')
-rw-r--r-- | hardinfo2/arch/linux/common/inputdevices.h | 4 | ||||
-rw-r--r-- | hardinfo2/arch/linux/common/modules.h | 11 | ||||
-rw-r--r-- | hardinfo2/arch/linux/common/pci.h | 4 | ||||
-rw-r--r-- | hardinfo2/arch/linux/common/storage.h | 8 | ||||
-rw-r--r-- | hardinfo2/arch/linux/common/usb.h | 4 |
5 files changed, 19 insertions, 12 deletions
diff --git a/hardinfo2/arch/linux/common/inputdevices.h b/hardinfo2/arch/linux/common/inputdevices.h index a3fb3e4a..e9deffa7 100644 --- a/hardinfo2/arch/linux/common/inputdevices.h +++ b/hardinfo2/arch/linux/common/inputdevices.h @@ -55,7 +55,7 @@ scan_inputdevices(void) return; if (input_list) { - g_hash_table_foreach_remove(devices, remove_input_devices, NULL); + g_hash_table_foreach_remove(moreinfo, remove_input_devices, NULL); g_free(input_list); g_free(input_icons); } @@ -127,7 +127,7 @@ scan_inputdevices(void) "Version=0x%x\n" "Connected to=%s\n", strhash, product, version, phys); - g_hash_table_insert(devices, tmp, strhash); + g_hash_table_insert(moreinfo, tmp, strhash); g_free(phys); g_free(name); diff --git a/hardinfo2/arch/linux/common/modules.h b/hardinfo2/arch/linux/common/modules.h index 933823d7..3acf4aba 100644 --- a/hardinfo2/arch/linux/common/modules.h +++ b/hardinfo2/arch/linux/common/modules.h @@ -16,6 +16,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#define GET_STR(field_name,ptr) \ + if (!ptr && strstr(tmp[0], field_name)) { \ + ptr = g_markup_escape_text(g_strstrip(tmp[1]), strlen(tmp[1])); \ + g_strfreev(tmp); \ + continue; \ + } + static gboolean remove_module_devices(gpointer key, gpointer value, gpointer data) { @@ -40,7 +47,7 @@ scan_modules(void) module_list = NULL; } - g_hash_table_foreach_remove(devices, remove_module_devices, NULL); + g_hash_table_foreach_remove(moreinfo, remove_module_devices, NULL); lsmod = popen("/sbin/lsmod", "r"); if (!lsmod) @@ -137,7 +144,7 @@ scan_modules(void) g_free(deps); } - g_hash_table_insert(devices, hashkey, strmodule); + g_hash_table_insert(moreinfo, hashkey, strmodule); g_free(license); g_free(description); diff --git a/hardinfo2/arch/linux/common/pci.h b/hardinfo2/arch/linux/common/pci.h index e7c940bb..5f48ba44 100644 --- a/hardinfo2/arch/linux/common/pci.h +++ b/hardinfo2/arch/linux/common/pci.h @@ -126,7 +126,7 @@ scan_pci(void) gpointer start, end; if (strdevice != NULL && strhash != NULL) { - g_hash_table_insert(devices, strhash, strdevice); + g_hash_table_insert(moreinfo, strhash, strdevice); g_free(category); g_free(name); } @@ -194,7 +194,7 @@ scan_pci(void) pci_list = g_strconcat(pci_list, "No PCI devices found=\n", NULL); } else if (strhash) { /* insert the last device */ - g_hash_table_insert(devices, strhash, strdevice); + g_hash_table_insert(moreinfo, strhash, strdevice); g_free(category); g_free(name); } diff --git a/hardinfo2/arch/linux/common/storage.h b/hardinfo2/arch/linux/common/storage.h index 4c9b5633..3397570d 100644 --- a/hardinfo2/arch/linux/common/storage.h +++ b/hardinfo2/arch/linux/common/storage.h @@ -43,7 +43,7 @@ scan_scsi(void) gchar *vendor = NULL, *revision = NULL, *model = NULL; /* remove old devices from global device table */ - g_hash_table_foreach_remove(devices, remove_scsi_devices, NULL); + g_hash_table_foreach_remove(moreinfo, remove_scsi_devices, NULL); if (!g_file_test("/proc/scsi/scsi", G_FILE_TEST_EXISTS)) return; @@ -136,7 +136,7 @@ scan_scsi(void) scsi_channel, scsi_id, scsi_lun); - g_hash_table_insert(devices, devid, strhash); + g_hash_table_insert(moreinfo, devid, strhash); g_free(model); g_free(revision); @@ -169,7 +169,7 @@ scan_ide(void) gchar *capab = NULL, *speed = NULL, *driver = NULL; /* remove old devices from global device table */ - g_hash_table_foreach_remove(devices, remove_ide_devices, NULL); + g_hash_table_foreach_remove(moreinfo, remove_ide_devices, NULL); storage_list = g_strdup_printf("%s\n[IDE Disks]\n", storage_list); @@ -345,7 +345,7 @@ scan_ide(void) speed = NULL; } - g_hash_table_insert(devices, devid, strhash); + g_hash_table_insert(moreinfo, devid, strhash); g_free(model); model = ""; diff --git a/hardinfo2/arch/linux/common/usb.h b/hardinfo2/arch/linux/common/usb.h index 4fd6ee21..286d9380 100644 --- a/hardinfo2/arch/linux/common/usb.h +++ b/hardinfo2/arch/linux/common/usb.h @@ -47,7 +47,7 @@ scan_usb(void) return; if (usb_list) { - g_hash_table_foreach_remove(devices, remove_usb_devices, NULL); + g_hash_table_foreach_remove(moreinfo, remove_usb_devices, NULL); g_free(usb_list); } usb_list = g_strdup(""); @@ -125,7 +125,7 @@ scan_usb(void) ver, rev, classid, vendor, prodid, bus, level); - g_hash_table_insert(devices, tmp, strhash); + g_hash_table_insert(moreinfo, tmp, strhash); } g_free(manuf); |