From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:38324) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R776J-0004H2-UR for qemu-devel@nongnu.org; Fri, 23 Sep 2011 10:51:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R776I-0004Ja-Ug for qemu-devel@nongnu.org; Fri, 23 Sep 2011 10:51:39 -0400 Received: from e2.ny.us.ibm.com ([32.97.182.142]:52207) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R776I-0004JW-NQ for qemu-devel@nongnu.org; Fri, 23 Sep 2011 10:51:38 -0400 Received: from /spool/local by us.ibm.com with XMail ESMTP for from ; Fri, 23 Sep 2011 10:44:54 -0400 Received: from d01av01.pok.ibm.com (d01av01.pok.ibm.com [9.56.224.215]) by d01relay03.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p8NEiE6O252614 for ; Fri, 23 Sep 2011 10:44:14 -0400 Received: from d01av01.pok.ibm.com (loopback [127.0.0.1]) by d01av01.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p8NEi1vE023291 for ; Fri, 23 Sep 2011 10:44:02 -0400 Message-ID: <4E7C9B2A.6070305@us.ibm.com> Date: Fri, 23 Sep 2011 09:43:54 -0500 From: Anthony Liguori MIME-Version: 1.0 References: <4E72809B.8000209@web.de> In-Reply-To: <4E72809B.8000209@web.de> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] vga: Fix text mode screendumps List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jan Kiszka Cc: qemu-devel , Andriy Gapon On 09/15/2011 05:47 PM, Jan Kiszka wrote: > From: Jan Kiszka > > In text mode, even a full refresh of the screen takes multiple updates. > As we reset the dump file pointer after the first call, we only wrote > the first line. > > Signed-off-by: Jan Kiszka Applied. Thanks. Regards, Anthony Liguori > --- > hw/vga.c | 7 +++---- > 1 files changed, 3 insertions(+), 4 deletions(-) > > diff --git a/hw/vga.c b/hw/vga.c > index 0a0c5a6..f9a6014 100644 > --- a/hw/vga.c > +++ b/hw/vga.c > @@ -149,7 +149,7 @@ static uint16_t expand2[256]; > static uint8_t expand4to8[16]; > > static void vga_screen_dump(void *opaque, const char *filename); > -static char *screen_dump_filename; > +static const char *screen_dump_filename; > static DisplayChangeListener *screen_dump_dcl; > > static void vga_update_memory_access(VGACommonState *s) > @@ -2319,7 +2319,6 @@ static void vga_save_dpy_update(DisplayState *ds, > { > if (screen_dump_filename) { > ppm_save(screen_dump_filename, ds->surface); > - screen_dump_filename = NULL; > } > } > > @@ -2397,8 +2396,8 @@ static void vga_screen_dump(void *opaque, const char *filename) > if (!screen_dump_dcl) > screen_dump_dcl = vga_screen_dump_init(s->ds); > > - screen_dump_filename = (char *)filename; > + screen_dump_filename = filename; > vga_invalidate_display(s); > vga_hw_update(); > + screen_dump_filename = NULL; > } > - > >