Received: from eggs.gnu.org ([140.186.70.92]:45944) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QTt5F-0008KG-Ub for qemu-devel@nongnu.org; Tue, 07 Jun 2011 06:00:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QTt5B-00030m-Kk for qemu-devel@nongnu.org; Tue, 07 Jun 2011 06:00:25 -0400 Received: from cantor.suse.de ([195.135.220.2]:47954 helo=mx1.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QTt5B-00030Q-CL for qemu-devel@nongnu.org; Tue, 07 Jun 2011 06:00:21 -0400 From: Alexander Graf Date: Mon, 6 Jun 2011 06:55:42 +0200 Message-Id: <1307336142-13459-1-git-send-email-agraf@suse.de> Subject: [Qemu-devel] [PATCH] console: add question-mark escape operator List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "qemu-devel@nongnu.org Developers" Cc: Anthony Liguori Some termcaps (found using SLES11SP1) use [? sequences. According to man console_codes (http://linux.die.net/man/4/console_codes) the question mark is a nop and should simply be ignored. This patch does exactly that, rendering screen output readable when outputting guest serial consoles to the graphical console emulator. Signed-off-by: Alexander Graf --- console.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/console.c b/console.c index 871c1d4..5e8e35d 100644 --- a/console.c +++ b/console.c @@ -905,7 +905,7 @@ static void console_putchar(TextConsole *s, int ch) } } else { s->nb_esc_params++; - if (ch == ';') + if (ch == ';' || ch == '?') break; #ifdef DEBUG_CONSOLE fprintf(stderr, "escape sequence CSI%d;%d%c, %d parameters\n", -- 1.6.0.2