Re: [PATCH 02/32] qemu: backup: Fix backup of disk skipped in an intermediate checkpoint

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

 



On Wed, Jun 17, 2020 at 13:21:04 -0500, Eric Blake wrote:
> On 6/15/20 12:09 PM, Peter Krempa wrote:
> > If a disk is not captured by one of the intermediate checkpoints the
> > code would fail, but we can easily calculate the bitmaps to merge
> > correctly by skipping over checkpoints which don't describe the disk.

[...]

> > diff --git a/tests/qemublocktest.c b/tests/qemublocktest.c
> > index 0cdedb9ad4..f00d2ff129 100644
> > --- a/tests/qemublocktest.c
> > +++ b/tests/qemublocktest.c
> > @@ -727,6 +727,12 @@ testQemuBackupGetIncrementalMoment(const char *name)
> >       if (!(checkpoint = virDomainCheckpointDefNew()))
> >           abort();
> > 
> > +    checkpoint->disks = g_new0(virDomainCheckpointDiskDef, 1);
> > +    checkpoint->ndisks = 1;
> > +
> > +    checkpoint->disks[0].name = g_strdup("testdisk");
> > +    checkpoint->disks[0].type = VIR_DOMAIN_CHECKPOINT_TYPE_BITMAP;
> > +
> 
> I'm not quite sure how this test change matches the code change above, but
> the code change looked reasonable.

This doesn't really test the change but allows previous tests to work,
by actually creating the metadata for a disk named 'testdisk' in the
fake checkpoint object which was not needed for backup before.




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux