Re: [PATCH 2/2] sysinfo: Fix reports on arm

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 05/12/2015 10:23 AM, Michal Privoznik wrote:
> Due to a commit in kernel (155597223) it's 'processor' rather than
> 'Processor'. Fix our parser too.

Shouldn't we be parsing this string case-insensitively, to work with
kernels that pre-date that kernel commit?

> 
> Signed-off-by: Michal Privoznik <mprivozn@xxxxxxxxxx>
> ---
>  src/util/virsysinfo.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/util/virsysinfo.c b/src/util/virsysinfo.c
> index 8bb17f0..fb8cb2c 100644
> --- a/src/util/virsysinfo.c
> +++ b/src/util/virsysinfo.c
> @@ -289,7 +289,7 @@ virSysinfoParseProcessor(const char *base, virSysinfoDefPtr ret)
>      virSysinfoProcessorDefPtr processor;
>      char *processor_type = NULL;
>  
> -    if (!(tmp_base = strstr(base, "Processor")))
> +    if (!(tmp_base = strstr(base, "processor")))
>          return 0;
>  
>      base = tmp_base;
> 

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]