mirror of
https://github.com/anrieff/libcpuid
synced 2024-11-10 22:59:13 +00:00
Fix null pointer dereference in cpuid_deserialize_raw_data_internal
This commit is contained in:
parent
b1732e4785
commit
2ec692b579
1 changed files with 5 additions and 3 deletions
|
@ -437,9 +437,11 @@ static int cpuid_deserialize_raw_data_internal(struct cpu_raw_data_t* single_raw
|
|||
}
|
||||
if (i >= 0) {
|
||||
debugf(2, "Parsing RAW dump for a single CPU dump\n");
|
||||
cpuid_grow_raw_data_array(raw_array, 1);
|
||||
raw_ptr = &raw_array->raw[0];
|
||||
raw_array->with_affinity = false;
|
||||
if (use_raw_array) {
|
||||
cpuid_grow_raw_data_array(raw_array, 1);
|
||||
raw_ptr = &raw_array->raw[0];
|
||||
raw_array->with_affinity = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!strcmp(line, "------[ Versions ]------") || !strcmp(line, "------[ Logical CPU #0 ]------") || !strcmp(line, "------[ CPUID Registers / Logical CPU #0 ]------")) {
|
||||
|
|
Loading…
Reference in a new issue