WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] fix few variable initializations

To: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH] fix few variable initializations
From: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Date: Tue, 04 Nov 2008 12:09:13 +0000
Delivery-date: Tue, 04 Nov 2008 04:06:41 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.14 (X11/20080505)
Fix few variable initializations.

Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>

---

diff --git a/hw/vga.c b/hw/vga.c
index f2ce4fe..dc1f8ec 100644
--- a/hw/vga.c
+++ b/hw/vga.c
@@ -2493,7 +2493,7 @@ void vga_common_init(VGAState *s, DisplayState *ds, 
uint8_t *vga_ram_base,
 
     vga_reset(s);
 
-    s->vram_ptr = qemu_malloc(vga_ram_size);
+    s->vram_ptr = qemu_mallocz(vga_ram_size);
     s->vram_mfns = NULL;
     xen_vga_state = s;
 
@@ -2652,7 +2652,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/vl.c b/vl.c
index d72acac..a699361 100644
--- a/vl.c
+++ b/vl.c
@@ -2632,6 +2632,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);

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] fix few variable initializations, Stefano Stabellini <=