aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--hw/vga.c2
-rw-r--r--qemu-char.c1
2 files changed, 2 insertions, 1 deletions
diff --git a/hw/vga.c b/hw/vga.c
index 9540db0343..ca8acfe24e 100644
--- a/hw/vga.c
+++ b/hw/vga.c
@@ -2396,7 +2396,7 @@ static void vga_save_dpy_update(DisplayState *s,
static void vga_save_dpy_resize(DisplayState *s, int w, int h)
{
s->linesize = w * 4;
- s->data = qemu_malloc(h * s->linesize);
+ s->data = qemu_mallocz(h * s->linesize);
vga_save_w = w;
vga_save_h = h;
}
diff --git a/qemu-char.c b/qemu-char.c
index ad57948173..2cf8644542 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -941,6 +941,7 @@ static CharDriverState *qemu_chr_open_pty(void)
}
/* Set raw attributes on the pty. */
+ tcgetattr(slave_fd, &tty);
cfmakeraw(&tty);
tcsetattr(slave_fd, TCSAFLUSH, &tty);
close(slave_fd);