qemu-char: do not forward events through the mux until QEMU has started
commitfffbd9cf1befa256d75bc45541adca405bb65dd5
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 27 Oct 2016 13:38:19 +0000 (27 15:38 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 2 Nov 2016 08:28:56 +0000 (2 09:28 +0100)
treeabfed1f45d6cc8907b19549a37916267b428c54c
parentfa778fffdfafce811bba3dd97de41fb524b861f7
qemu-char: do not forward events through the mux until QEMU has started

Otherwise, the CHR_EVENT_OPENED event is sent twice: first when the
backend (for example "stdio") is opened, and second after processing
the command line.

The incorrect sending of the event prints the monitor banner when
QEMU is started with "-serial mon:stdio".  This includes the "(qemu)"
prompt; thus the monitor seems to be dead, whereas actually the
active front-end is the serial port.

Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Tested-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
qemu-char.c