]> git.proxmox.com Git - qemu.git/blobdiff - qemu-char.c
target-mips: Remove unused inline function
[qemu.git] / qemu-char.c
index bb9e3f50a85e41e6cfe9603c84ca71183c48fd2e..a9fc50481aeb6665dac2f4b1459662254b9bb1c1 100644 (file)
@@ -160,7 +160,9 @@ int qemu_chr_be_can_write(CharDriverState *s)
 
 void qemu_chr_be_write(CharDriverState *s, uint8_t *buf, int len)
 {
-    s->chr_read(s->handler_opaque, buf, len);
+    if (s->chr_read) {
+        s->chr_read(s->handler_opaque, buf, len);
+    }
 }
 
 int qemu_chr_fe_get_msgfd(CharDriverState *s)
@@ -177,6 +179,7 @@ void qemu_chr_accept_input(CharDriverState *s)
 {
     if (s->chr_accept_input)
         s->chr_accept_input(s);
+    qemu_notify_event();
 }
 
 void qemu_chr_fe_printf(CharDriverState *s, const char *fmt, ...)