From 9208df385f99d809f53ed3dc5c07a39cceace052 Mon Sep 17 00:00:00 2001 From: La Stik Date: Tue, 30 Jun 2009 20:31:20 +0800 Subject: - Adding CoreDuo identification - With processors with much instructions, not all of them are shown Signed-off-by: Leandro A. F. Pereira --- hardinfo2/arch/linux/x86/processor.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'hardinfo2') diff --git a/hardinfo2/arch/linux/x86/processor.h b/hardinfo2/arch/linux/x86/processor.h index 8f918581..273b0578 100644 --- a/hardinfo2/arch/linux/x86/processor.h +++ b/hardinfo2/arch/linux/x86/processor.h @@ -71,7 +71,7 @@ static void get_processor_strfamily(Processor * processor) } else if (model == 9) { processor->strmodel = g_strdup("Pentium M"); } else { - processor->strmodel = g_strdup("Pentium III/Pentium III Xeon/Celeron"); + processor->strmodel = g_strdup("Pentium III/Pentium III Xeon/Celeron/Core Duo/Core Duo 2"); } } else if (family > 6) { processor->strmodel = g_strdup("Pentium 4"); @@ -244,14 +244,14 @@ static GSList *__scan_processors(void) GSList *procs = NULL; Processor *processor = NULL; FILE *cpuinfo; - gchar buffer[256]; + gchar buffer[512]; gint processor_number = 0; cpuinfo = fopen("/proc/cpuinfo", "r"); if (!cpuinfo) return NULL; - while (fgets(buffer, 256, cpuinfo)) { + while (fgets(buffer, 512, cpuinfo)) { gchar **tmp = g_strsplit(buffer, ":", 2); if (g_str_has_prefix(tmp[0], "processor")) { -- cgit v1.2.3