mirror of https://github.com/xemu-project/xemu.git
qemu-ga: ask and print error information from qemu-sockets
Reviewed-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
f8430e7621
commit
90119816e3
|
@ -181,9 +181,11 @@ static gboolean ga_channel_open(GAChannel *c, const gchar *path, GAChannelMethod
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case GA_CHANNEL_UNIX_LISTEN: {
|
case GA_CHANNEL_UNIX_LISTEN: {
|
||||||
int fd = unix_listen(path, NULL, strlen(path), NULL);
|
Error *local_err = NULL;
|
||||||
if (fd == -1) {
|
int fd = unix_listen(path, NULL, strlen(path), &local_err);
|
||||||
g_critical("error opening path: %s", strerror(errno));
|
if (local_err != NULL) {
|
||||||
|
g_critical("%s", error_get_pretty(local_err));
|
||||||
|
error_free(local_err);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
ga_channel_listen_add(c, fd, true);
|
ga_channel_listen_add(c, fd, true);
|
||||||
|
|
Loading…
Reference in New Issue