提交 63910128 编写于 作者: B Bjoern Walk 提交者: Michal Privoznik

tools: virt-host-validate: fix CPU flag detection

Let's fix CPU flag detection on s390, where the flags line begins with
a lower-case 'features'.
Signed-off-by: NBjoern Walk <bwalk@linux.vnet.ibm.com>
上级 45c2dcfb
......@@ -212,10 +212,11 @@ virBitmapPtr virHostValidateGetCPUFlags(void)
if (!fgets(line, sizeof(line), fp))
break;
/* The line we're interested in is marked either as "flags" or
* as "Features" depending on the architecture, so check both
* prefixes */
if (!STRPREFIX(line, "flags") && !STRPREFIX(line, "Features"))
/* The line we're interested in is marked differently depending
* on the architecture, so check possible prefixes */
if (!STRPREFIX(line, "flags") &&
!STRPREFIX(line, "Features") &&
!STRPREFIX(line, "features"))
continue;
/* fgets() includes the trailing newline in the output buffer,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册