aboutsummaryrefslogtreecommitdiff
path: root/monitor.c
diff options
context:
space:
mode:
authoraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2008-08-19 14:44:22 +0000
committeraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2008-08-19 14:44:22 +0000
commit83ab7950d23f037a665d17806fc903ca3565510c (patch)
tree1b22c134d433c09379178089affe6b66c9eedd73 /monitor.c
parentf99ed40ad8f089eb18bf19c9473e72bb2d257c92 (diff)
Revert r4979 since it breaks the monitor
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5028 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'monitor.c')
-rw-r--r--monitor.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/monitor.c b/monitor.c
index 0a3027cc77..47c5514745 100644
--- a/monitor.c
+++ b/monitor.c
@@ -76,6 +76,8 @@ static term_cmd_t info_cmds[];
static uint8_t term_outbuf[1024];
static int term_outbuf_index;
+static void monitor_start_input(void);
+
CPUState *mon_cpu = NULL;
void term_flush(void)
@@ -2683,13 +2685,15 @@ static void term_read(void *opaque, const uint8_t *buf, int size)
readline_handle_byte(buf[i]);
}
+static void monitor_start_input(void);
+
static void monitor_handle_command1(void *opaque, const char *cmdline)
{
monitor_handle_command(cmdline);
monitor_start_input();
}
-void monitor_start_input(void)
+static void monitor_start_input(void)
{
readline_start("(qemu) ", 0, monitor_handle_command1, NULL);
}
@@ -2730,6 +2734,8 @@ void monitor_init(CharDriverState *hd, int show_banner)
hide_banner = !show_banner;
qemu_chr_add_handlers(hd, term_can_read, term_read, term_event, NULL);
+
+ readline_start("", 0, monitor_handle_command1, NULL);
}
/* XXX: use threads ? */