[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] How do I disable -curses mode?

From: Rob Landley
Subject: [Qemu-devel] How do I disable -curses mode?
Date: Thu, 8 Oct 2009 03:03:25 -0500
User-agent: KMail/1.11.2 (Linux/2.6.28-15-generic; KDE/4.2.2; x86_64; ; )

I'm running qemu -nographic from a script, booting up a linux -kernel with a 
serial console and driving it via "expect" to feed data to its stdin and parse 
its output.

This worked fine under 0.10.0, but under 0.11.0 it craps curses escape 
sequences all over the place, ala:

Type exit when done.
/ #        #
^[[24;5R/ # # Show free space
/ # df
^[[24;13R^[[24;5RFilesystem           1K-blocks      Used Available Use% 
Mounted on

This confuses "expect" because it doesn't get the lines it's looking for, 
those escape sequences can show up in the middle of a line.

I'm already saying -nographic, which vl.c seems to imply is a different code 
path from -curses, yet it's spitting all this extra stuff to the output anyway.

If I recompile telling ./configure to --disable-curses the problem goes away, 
but I can't tell distro maintainers to do that and I can't always build qemu 
from source.

In this instance neither qemu's stdin nor its stdout is a tty, so you'd think 
the curses code would NOTICE.  (It's not that hard to call ttyname() on stdin 
and see if you get a null pointer, is it?)

Latency is more important than throughput. It's that simple. - Linus Torvalds

reply via email to

[Prev in Thread] Current Thread [Next in Thread]