Signed-off-by: Jiri Denemark <jdenemar(a)redhat.com>
---
Notes:
Version 2:
- no change
src/cpu/cpu_x86.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/cpu/cpu_x86.c b/src/cpu/cpu_x86.c
index 904b59c..d0e1a1a 100644
--- a/src/cpu/cpu_x86.c
+++ b/src/cpu/cpu_x86.c
@@ -2653,8 +2653,11 @@ x86HasFeature(const virCPUData *data,
return -1;
if (!(feature = x86FeatureFind(map, name)) &&
- !(feature = x86FeatureFindInternal(name)))
+ !(feature = x86FeatureFindInternal(name))) {
+ virReportError(VIR_ERR_INTERNAL_ERROR,
+ _("unknown CPU feature %s"), name);
goto cleanup;
+ }
ret = x86DataIsSubset(&data->data.x86, &feature->data) ? 1 : 0;
--
2.10.0