Patchwork fix 'i' format handling in memory dump

login
register
mail settings
Submitter Gleb Natapov
Date Feb. 21, 2010, 2:23 p.m.
Message ID <20100221142320.GP14767@redhat.com>
Download mbox | patch
Permalink /patch/45948/
State New
Headers show

Comments

Gleb Natapov - Feb. 21, 2010, 2:23 p.m.
It was broken by 09b9418c6d0. (!env && !is_physical) != (!is_physical) 
when env is true.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
--
			Gleb.
Markus Armbruster - Feb. 22, 2010, 9:51 a.m.
Gleb Natapov <gleb@redhat.com> writes:

> It was broken by 09b9418c6d0. (!env && !is_physical) != (!is_physical) 
> when env is true.
>
> Signed-off-by: Gleb Natapov <gleb@redhat.com>
> diff --git a/monitor.c b/monitor.c
> index b1a6edc..19470d1 100644
> --- a/monitor.c
> +++ b/monitor.c
> @@ -1297,8 +1297,6 @@ static void memory_dump(Monitor *mon, int count, int format, int wsize,
>          int flags;
>          flags = 0;
>          env = mon_get_cpu();
> -        if (!is_physical)
> -            return;
>  #ifdef TARGET_I386
>          if (wsize == 2) {
>              flags = 1;

*Ouch*

I checked the offending commit for more such errors, but couldn't find
any.

Patch

diff --git a/monitor.c b/monitor.c
index b1a6edc..19470d1 100644
--- a/monitor.c
+++ b/monitor.c
@@ -1297,8 +1297,6 @@  static void memory_dump(Monitor *mon, int count, int format, int wsize,
         int flags;
         flags = 0;
         env = mon_get_cpu();
-        if (!is_physical)
-            return;
 #ifdef TARGET_I386
         if (wsize == 2) {
             flags = 1;