aboutsummaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
Diffstat (limited to 'ui')
-rw-r--r--ui/dbus-listener.c22
-rw-r--r--ui/gtk.c6
-rw-r--r--ui/qemu-pixman.c5
-rw-r--r--ui/spice-core.c6
-rw-r--r--ui/vdagent.c8
5 files changed, 34 insertions, 13 deletions
diff --git a/ui/dbus-listener.c b/ui/dbus-listener.c
index 42875b8..52e041e 100644
--- a/ui/dbus-listener.c
+++ b/ui/dbus-listener.c
@@ -214,24 +214,32 @@ static void dbus_update_gl_cb(GObject *source_object,
GAsyncResult *res,
gpointer user_data)
{
- g_autoptr(GError) err = NULL;
+ g_autoptr(GError) gerr = NULL;
+#ifdef WIN32
+ Error *err = NULL;
+#endif
DBusDisplayListener *ddl = user_data;
bool success;
#ifdef CONFIG_GBM
success = qemu_dbus_display1_listener_call_update_dmabuf_finish(
- ddl->proxy, res, &err);
+ ddl->proxy, res, &gerr);
+ if (!success) {
+ error_report("Failed to call update: %s", gerr->message);
+ }
#endif
#ifdef WIN32
success = qemu_dbus_display1_listener_win32_d3d11_call_update_texture2d_finish(
- ddl->d3d11_proxy, res, &err);
- d3d_texture2d_acquire0(ddl->d3d_texture, &error_warn);
-#endif
-
+ ddl->d3d11_proxy, res, &gerr);
if (!success) {
- error_report("Failed to call update: %s", err->message);
+ error_report("Failed to call update: %s", gerr->message);
+ }
+
+ if (!d3d_texture2d_acquire0(ddl->d3d_texture, &err)) {
+ error_report_err(err);
}
+#endif
graphic_hw_gl_block(ddl->dcl.con, false);
g_object_unref(ddl);
diff --git a/ui/gtk.c b/ui/gtk.c
index e91d093..9a08cad 100644
--- a/ui/gtk.c
+++ b/ui/gtk.c
@@ -1181,6 +1181,7 @@ static gboolean gd_touch_event(GtkWidget *widget, GdkEventTouch *touch,
void *opaque)
{
VirtualConsole *vc = opaque;
+ Error *err = NULL;
uint64_t num_slot = GPOINTER_TO_UINT(touch->sequence);
int type = -1;
@@ -1203,7 +1204,10 @@ static gboolean gd_touch_event(GtkWidget *widget, GdkEventTouch *touch,
console_handle_touch_event(vc->gfx.dcl.con, touch_slots,
num_slot, surface_width(vc->gfx.ds),
surface_height(vc->gfx.ds), touch->x,
- touch->y, type, &error_warn);
+ touch->y, type, &err);
+ if (err) {
+ warn_report_err(err);
+ }
return TRUE;
}
diff --git a/ui/qemu-pixman.c b/ui/qemu-pixman.c
index ef4e71d..e46c623 100644
--- a/ui/qemu-pixman.c
+++ b/ui/qemu-pixman.c
@@ -288,7 +288,10 @@ qemu_pixman_shareable_free(qemu_pixman_shareable handle,
void *ptr, size_t size)
{
#ifdef WIN32
- qemu_win32_map_free(ptr, handle, &error_warn);
+ Error *err = NULL;
+
+ qemu_win32_map_free(ptr, handle, &err);
+ error_report_err(err);
#else
qemu_memfd_free(ptr, size, handle);
#endif
diff --git a/ui/spice-core.c b/ui/spice-core.c
index 2645e96..8a6050f 100644
--- a/ui/spice-core.c
+++ b/ui/spice-core.c
@@ -126,11 +126,13 @@ static void watch_update_mask(SpiceWatch *watch, int event_mask)
static SpiceWatch *watch_add(int fd, int event_mask, SpiceWatchFunc func, void *opaque)
{
SpiceWatch *watch;
-
#ifdef WIN32
+ g_autofree char *msg = NULL;
+
fd = _open_osfhandle(fd, _O_BINARY);
if (fd < 0) {
- error_setg_win32(&error_warn, WSAGetLastError(), "Couldn't associate a FD with the SOCKET");
+ msg = g_win32_error_message(WSAGetLastError());
+ warn_report("Couldn't associate a FD with the SOCKET: %s", msg);
return NULL;
}
#endif
diff --git a/ui/vdagent.c b/ui/vdagent.c
index c0746fe..ddb91e7 100644
--- a/ui/vdagent.c
+++ b/ui/vdagent.c
@@ -992,7 +992,8 @@ static int put_cbinfo(QEMUFile *f, void *pv, size_t size,
}
}
- return vmstate_save_state(f, &vmstate_cbinfo_array, &cbinfo, vmdesc);
+ return vmstate_save_state(f, &vmstate_cbinfo_array, &cbinfo, vmdesc,
+ &error_fatal);
}
static int get_cbinfo(QEMUFile *f, void *pv, size_t size,
@@ -1001,6 +1002,7 @@ static int get_cbinfo(QEMUFile *f, void *pv, size_t size,
VDAgentChardev *vd = QEMU_VDAGENT_CHARDEV(pv);
struct CBInfoArray cbinfo = {};
int i, ret;
+ Error *local_err = NULL;
if (!have_clipboard(vd)) {
return 0;
@@ -1008,8 +1010,10 @@ static int get_cbinfo(QEMUFile *f, void *pv, size_t size,
vdagent_clipboard_peer_register(vd);
- ret = vmstate_load_state(f, &vmstate_cbinfo_array, &cbinfo, 0);
+ ret = vmstate_load_state(f, &vmstate_cbinfo_array, &cbinfo, 0,
+ &local_err);
if (ret) {
+ error_report_err(local_err);
return ret;
}