Received: from eggs.gnu.org ([2001:4830:134:3::10]:37611) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VxYVI-0007MW-Jt for qemu-devel@nongnu.org; Mon, 30 Dec 2013 03:47:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VxYV9-0005xJ-V4 for qemu-devel@nongnu.org; Mon, 30 Dec 2013 03:47:16 -0500 From: Kewei Yu Date: Mon, 30 Dec 2013 16:46:55 +0800 Message-Id: <1388393215-27511-1-git-send-email-keweihk@gmail.com> Subject: [Qemu-devel] [PATCH 1/1] qtest:Fix the bug about disabling vnc causes "make check" hang List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: qemu-trivial@nongnu.org, mst@redhat.com When we disabling vnc from "./configure", the qemu can't use the vnc option. So qtest can't use the "vnc -none ", otherwise "make check" will hang. Signed-off-by: Kewei Yu --- tests/fdc-test.c | 4 ++++ tests/ide-test.c | 11 ++++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/tests/fdc-test.c b/tests/fdc-test.c index 38b5b17..80dbdfb 100644 --- a/tests/fdc-test.c +++ b/tests/fdc-test.c @@ -538,7 +538,11 @@ int main(int argc, char **argv) /* Run the tests */ g_test_init(&argc, &argv, NULL); +#ifdef CONFIG_VNC cmdline = g_strdup_printf("-vnc none "); +#else + cmdline = NULL; +#endif qtest_start(cmdline); qtest_irq_intercept_in(global_qtest, "ioapic"); diff --git a/tests/ide-test.c b/tests/ide-test.c index d5cec5a..da9e8dd 100644 --- a/tests/ide-test.c +++ b/tests/ide-test.c @@ -377,10 +377,15 @@ static void test_bmdma_no_busmaster(void) assert_bit_clear(inb(IDE_BASE + reg_status), DF | ERR); } +#ifdef CONFIG_VNC +#define QTEST_VNC_PARAM "-vnc none "; +#else +#define QTEST_VNC_PARAM +#endif static void test_bmdma_setup(void) { ide_test_start( - "-vnc none " + QTEST_VNC_PARAM "-drive file=%s,if=ide,serial=%s,cache=writeback " "-global ide-hd.ver=%s", tmp_path, "testdisk", "version"); @@ -410,7 +415,7 @@ static void test_identify(void) int ret; ide_test_start( - "-vnc none " + QTEST_VNC_PARAM "-drive file=%s,if=ide,serial=%s,cache=writeback " "-global ide-hd.ver=%s", tmp_path, "testdisk", "version"); @@ -455,7 +460,7 @@ static void test_flush(void) uint8_t data; ide_test_start( - "-vnc none " + QTEST_VNC_PARAM "-drive file=blkdebug::%s,if=ide,cache=writeback", tmp_path); -- 1.7.1