summaryrefslogtreecommitdiff
path: root/qemu-char.c
diff options
context:
space:
mode:
Diffstat (limited to 'qemu-char.c')
-rw-r--r--qemu-char.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/qemu-char.c b/qemu-char.c
index 84f49acbac..8575c54c98 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -3966,19 +3966,19 @@ void qemu_chr_fe_event(struct CharDriverState *chr, int event)
}
}
-int qemu_chr_fe_add_watch(CharDriverState *s, GIOCondition cond,
- GIOFunc func, void *user_data)
+guint qemu_chr_fe_add_watch(CharDriverState *s, GIOCondition cond,
+ GIOFunc func, void *user_data)
{
GSource *src;
guint tag;
if (s->chr_add_watch == NULL) {
- return -ENOSYS;
+ return 0;
}
src = s->chr_add_watch(s, cond);
if (!src) {
- return -EINVAL;
+ return 0;
}
g_source_set_callback(src, (GSourceFunc)func, user_data, NULL);