qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v1] hmp: 'info snapshots' not showing the id


From: Dr. David Alan Gilbert
Subject: Re: [Qemu-devel] [PATCH v1] hmp: 'info snapshots' not showing the id
Date: Tue, 12 Dec 2017 16:41:15 +0000
User-agent: Mutt/1.9.1 (2017-09-22)

* Seeteena Thoufeek (address@hidden) wrote:
> (qemu) info snapshots
> List of snapshots present on all disks:
> ID        TAG                 VM SIZE                DATE       VM CLOCK
> --         1                      314M 2017-11-15 15:22:18   00:02:25.695
> --         2                      319M 2017-11-15 15:23:03   00:02:45.970
> --         3                      319M 2017-11-15 15:23:37   00:02:56.328
> 
> ID field is showing -- with no information.
> 
> Signed-off-by: Seeteena Thoufeek <address@hidden>

Hi Seeteena,
  Your change doesn't seem to be consistent with the comment above it.
I don't know the detailed history of snapshots, but that comment and the
pstrcpy comes from Lin Ma's commit 3a1ee711 which seems to be saying the
ID can't be trusted.

Dave

> ---
>  hmp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/hmp.c b/hmp.c
> index 35a7041..1921b3b 100644
> --- a/hmp.c
> +++ b/hmp.c
> @@ -1454,7 +1454,7 @@ void hmp_info_snapshots(Monitor *mon, const QDict 
> *qdict)
>              /* The ID is not guaranteed to be the same on all images, so
>               * overwrite it.
>               */
> -            pstrcpy(sn->id_str, sizeof(sn->id_str), "--");
> +            pstrcpy(sn->id_str, sizeof(sn->id_str), sn->id_str);
>              bdrv_snapshot_dump((fprintf_function)monitor_printf, mon, sn);
>              monitor_printf(mon, "\n");
>          }
> -- 
> 1.8.3.1
> 
--
Dr. David Alan Gilbert / address@hidden / Manchester, UK



reply via email to

[Prev in Thread] Current Thread [Next in Thread]