fix some variable initizalization issues
PATCH 1/1 fix some variable initizalization issues
Hi all,
this patch fixes two variable initialization issues.
Signed-off-by Stefano Stabellini <[email protected]>
---
hw/vga.c +1 -1
@@ -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; }
qemu-char.c +1 -0
@@ -935,6 +935,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);
I think this patch should be applied, makes valgrind happier :)
Quoted 35 lines · Stefano Stabellini
Hi all,
this patch fixes two variable initialization issues.Signed-off-by Stefano Stabellini <[email protected]>---
hw/vga.c +1
-1@@ -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; }qemu-char.c +1
-0@@ -935,6 +935,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);
Anthony Liguori
AppliedQuoted 4 lines · Stefano Stabellini
I think this patch should be applied, makes valgrind happier :)
Stefano Stabellini wrote:
Applied. Thanks.
Regards,
Anthony Liguori