[libvirt] [PATCH 16/30] storagefile: Don't access backingStoreRaw directly in FromBackingRelative

Cole Robinson crobinso at redhat.com
Mon Oct 7 21:49:30 UTC 2019


For the only usage, the rel == parent->backingStoreRaw, so drop
the direct access

Signed-off-by: Cole Robinson <crobinso at redhat.com>
---
 src/util/virstoragefile.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/virstoragefile.c b/src/util/virstoragefile.c
index 53fe4590b4..c47df6c200 100644
--- a/src/util/virstoragefile.c
+++ b/src/util/virstoragefile.c
@@ -2625,7 +2625,7 @@ virStorageSourceNewFromBackingRelative(virStorageSourcePtr parent,
         return NULL;
 
     /* store relative name */
-    if (VIR_STRDUP(def->relPath, parent->backingStoreRaw) < 0)
+    if (VIR_STRDUP(def->relPath, rel) < 0)
         return NULL;
 
     if (!(dirname = mdir_name(parent->path))) {
-- 
2.23.0




More information about the libvir-list mailing list