diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 73f570c41962b0733b05ac9047eed3b0a4f47e9a..5bf6c704e073fbc1e0ca93bc337064f6718aa3e1 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3573,7 +3573,7 @@ qemuBuildMemoryBackendProps(virJSONValuePtr *backendProps, pagesize = 0; needHugepage = false; useHugepage = false; - } else if (pagesize == 0) { + } else if (useHugepage && pagesize == 0) { if (qemuBuildMemoryGetDefaultPagesize(cfg, &pagesize) < 0) goto cleanup; }