It won't cause any harm as cpus is NULL when we pass a negative ncpus, but doing so when the function expects unsigned value is not right. Signed-off-by: Jiri Denemark <jdenemar@xxxxxxxxxx> --- src/conf/capabilities.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/conf/capabilities.c b/src/conf/capabilities.c index a3e68741a9..cea4803fc8 100644 --- a/src/conf/capabilities.c +++ b/src/conf/capabilities.c @@ -1954,6 +1954,7 @@ virCapabilitiesHostNUMAInitReal(virCapsHostNUMA *caps) if (ncpus == -2) continue; + ncpus = 0; goto cleanup; } -- 2.33.1