virtcontainers: check that both initrd and image are not set

This changed valid() in hypervisor to check the case where both
initrd and image path are set; in this case it returns an error.

Fixes #1868
Signed-off-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
This commit is contained in:
Wainer dos Santos Moschetta
2021-05-03 15:42:58 -04:00
parent 3120b489e3
commit 309dae631a
3 changed files with 15 additions and 1 deletions

View File

@@ -25,7 +25,6 @@ import (
func newQemuConfig() HypervisorConfig {
return HypervisorConfig{
KernelPath: testQemuKernelPath,
ImagePath: testQemuImagePath,
InitrdPath: testQemuInitrdPath,
HypervisorPath: testQemuPath,
NumVCPUs: defaultVCPUs,