mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 02:24:58 -06:00
char: allow specifying a GMainContext at opening time
This will be needed by vhost-user-test, when each test switches to its own GMainLoop and GMainContext. Otherwise, for a reconnecting socket the initial connection will happen on the default GMainContext, and no one will be listening on it. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20190202110834.24880-1-pbonzini@redhat.com> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
parent
211ef6c4b6
commit
4ad6f6cb14
17 changed files with 71 additions and 56 deletions
|
@ -44,7 +44,7 @@ static void isa_superio_realize(DeviceState *dev, Error **errp)
|
|||
chr = parallel_hds[i];
|
||||
if (chr == NULL) {
|
||||
name = g_strdup_printf("discarding-parallel%d", i);
|
||||
chr = qemu_chr_new(name, "null");
|
||||
chr = qemu_chr_new(name, "null", NULL);
|
||||
} else {
|
||||
name = g_strdup_printf("parallel%d", i);
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ static void isa_superio_realize(DeviceState *dev, Error **errp)
|
|||
chr = serial_hd(i);
|
||||
if (chr == NULL) {
|
||||
name = g_strdup_printf("discarding-serial%d", i);
|
||||
chr = qemu_chr_new(name, "null");
|
||||
chr = qemu_chr_new(name, "null", NULL);
|
||||
} else {
|
||||
name = g_strdup_printf("serial%d", i);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue