summaryrefslogtreecommitdiffstats
path: root/tests/qtest/machine-none-test.c
diff options
context:
space:
mode:
authorBin Meng2022-08-24 11:40:14 +0200
committerThomas Huth2022-08-29 15:28:51 +0200
commitde56338e068c97709febaf7ac45088b4b4eb0037 (patch)
treee690a5c6a6de1794de873eaf403a790830e8cd55 /tests/qtest/machine-none-test.c
parenttests/qtest: device-plug-test: Reverse the usage of double/single quotes (diff)
downloadqemu-de56338e068c97709febaf7ac45088b4b4eb0037.tar.gz
qemu-de56338e068c97709febaf7ac45088b4b4eb0037.tar.xz
qemu-de56338e068c97709febaf7ac45088b4b4eb0037.zip
tests/qtest: machine-none-test: Use double quotes to pass the cpu option
Single quotes in the arguments (e.g.: -cpu 'qemu64,apic-id=0') are not removed in the Windows environment before it is passed to the QEMU executable. Such argument causes a failure in the QEMU CPU option parser codes. Change to use double quotes which works fine on all platforms. Signed-off-by: Bin Meng <bin.meng@windriver.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Message-Id: <20220824094029.1634519-37-bmeng.cn@gmail.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to 'tests/qtest/machine-none-test.c')
-rw-r--r--tests/qtest/machine-none-test.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/qtest/machine-none-test.c b/tests/qtest/machine-none-test.c
index f92fab479f..31cc0bfb01 100644
--- a/tests/qtest/machine-none-test.c
+++ b/tests/qtest/machine-none-test.c
@@ -81,7 +81,7 @@ static void test_machine_cpu_cli(void)
" add it to cpus_map\n", arch);
return; /* TODO: die here to force all targets have a test */
}
- qts = qtest_initf("-machine none -cpu '%s'", cpu_model);
+ qts = qtest_initf("-machine none -cpu \"%s\"", cpu_model);
response = qtest_qmp(qts, "{ 'execute': 'quit' }");
g_assert(qdict_haskey(response, "return"));