[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 09/16] vhost-user-test: do not hang if chardev creati
From: |
Paolo Bonzini |
Subject: |
[Qemu-devel] [PULL 09/16] vhost-user-test: do not hang if chardev creation failed |
Date: |
Mon, 26 Mar 2018 15:36:36 +0200 |
From: Marc-André Lureau <address@hidden>
Before the chardev name fix, the following error may happen: "attempt
to add duplicate property 'chr-test' to object (type 'container')",
due to races.
Sadly, error_vprintf() uses g_test_message(), so you have to use
read the cryptic --debug-log to see it. Later, it would make sense to
use g_critical() instead, and catch errors with
g_test_expect_message() (in glib 2.34).
Signed-off-by: Marc-André Lureau <address@hidden>
Message-Id: <address@hidden>
Acked-by: Maxime Coquelin <address@hidden>
Signed-off-by: Paolo Bonzini <address@hidden>
---
tests/vhost-user-test.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/vhost-user-test.c b/tests/vhost-user-test.c
index 22e9202..f87afee 100644
--- a/tests/vhost-user-test.c
+++ b/tests/vhost-user-test.c
@@ -494,6 +494,7 @@ static void test_server_create_chr(TestServer *server,
const gchar *opt)
chr = qemu_chr_new(server->chr_name, chr_path);
g_free(chr_path);
+ g_assert_nonnull(chr);
qemu_chr_fe_init(&server->chr, chr, &error_abort);
qemu_chr_fe_set_handlers(&server->chr, chr_can_read, chr_read,
chr_event, NULL, server, NULL, true);
--
1.8.3.1
- [Qemu-devel] [PULL 02/16] WHPX fix WHvGetCapability out WrittenSizeInBytes, (continued)
- [Qemu-devel] [PULL 02/16] WHPX fix WHvGetCapability out WrittenSizeInBytes, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 03/16] WHPX fix WHvSetPartitionProperty in PropertyCode, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 04/16] WHPX improve vcpu_post_run perf, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 05/16] hw/net/can: Fix segfaults when using the devices without bus, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 01/16] scripts/get_maintainer.pl: Print proper error message for missing $file, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 07/16] hw/audio: Fix crashes when devices are used on ISA bus without DMA, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 06/16] fdc: Exit if ISA controller does not support DMA, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 08/16] scripts/device-crash-test: Remove fixed isapc-with-iommu entry, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 09/16] vhost-user-test: do not hang if chardev creation failed,
Paolo Bonzini <=
- [Qemu-devel] [PULL 11/16] tcg: Really fix cpu_io_recompile, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 12/16] chardev-socket: remove useless if, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 13/16] scsi: turn "is this a SCSI device?" into a conditional hint, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 14/16] iothread: fix breakage on windows, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 15/16] chardev/char-fe: Allow NULL chardev in qemu_chr_fe_init(), Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 10/16] vhost-user-test: add back memfd check, Paolo Bonzini, 2018/03/26
- [Qemu-devel] [PULL 16/16] qemu-pr-helper: Actually allow users to specify pidfile, Paolo Bonzini, 2018/03/26
- Re: [Qemu-devel] [PULL 00/16] Misc fixes for QEMU 2.12.0-rc1, Peter Maydell, 2018/03/27