mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
util: storage: Copy parent's disk metadata to backing chain elements
When discovering a disk backing chain the parent disk's metadata need to be populated into the guest images so that each piece of the backing chain contains a copy of those. This will allow us to refactor the security driver so that it will not need to carry around the original disk definition.
This commit is contained in:
parent
3bd69ab940
commit
6f87fb9b6f
@ -2315,9 +2315,17 @@ virStorageSourceNewFromBacking(virStorageSourcePtr parent)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* copy parent's labelling and other top level stuff */
|
||||
if (virStorageSourceInitChainElement(ret, parent, false) < 0)
|
||||
goto error;
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
||||
error:
|
||||
virStorageSourceFree(ret);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user