Always add 'console' matching the 'serial' device

We have been formatting the first serial device also
as a console device, but only if there were no other consoles.

If there is a <serial> device present in the XML, but no serial
<console>, or if there isn't any <console> at all but the domain
definition hasn't gone through a parse->format->parse round-trip,
the <console> device would not be formatted.

Change the code to always add the stub device for the first
serial device.

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1089914
This commit is contained in:
Ján Tomko
2014-08-13 13:06:04 +02:00
parent 12b949dfb2
commit 8728a78e90
4 changed files with 99 additions and 0 deletions

View File

@@ -472,6 +472,7 @@ mymain(void)
DO_TEST("serial-spiceport-nospice");
DO_TEST("parallel-tcp");
DO_TEST("console-compat");
DO_TEST_DIFFERENT("console-compat2");
DO_TEST("console-virtio-many");
DO_TEST("channel-guestfwd");
DO_TEST("channel-virtio");