|
|
0a7476 |
From 41651c5fbe6712dcca09cfc875af4d16c0f9fd68 Mon Sep 17 00:00:00 2001
|
|
|
0a7476 |
Message-Id: <41651c5fbe6712dcca09cfc875af4d16c0f9fd68@dist-git>
|
|
|
0a7476 |
From: John Ferlan <jferlan@redhat.com>
|
|
|
0a7476 |
Date: Wed, 3 Apr 2019 07:35:45 -0400
|
|
|
0a7476 |
Subject: [PATCH] storage: Remove secretPath from _virStorageBackendQemuImgInfo
|
|
|
0a7476 |
|
|
|
0a7476 |
https://bugzilla.redhat.com/show_bug.cgi?id=1613737
|
|
|
0a7476 |
|
|
|
0a7476 |
There's really no need for it to be there since it's only ever
|
|
|
0a7476 |
used inside virStorageBackendCreateQemuImgCmdFromVol
|
|
|
0a7476 |
|
|
|
0a7476 |
Signed-off-by: John Ferlan <jferlan@redhat.com>
|
|
|
0a7476 |
ACKed-by: Michal Privoznik <mprivozn@redhat.com>
|
|
|
0a7476 |
(cherry picked from commit f6aa977fab1108e652ab8c360a651045c727d02e)
|
|
|
0a7476 |
Message-Id: <20190403113547.29231-2-jferlan@redhat.com>
|
|
|
0a7476 |
Reviewed-by: Erik Skultety <eskultet@redhat.com>
|
|
|
0a7476 |
---
|
|
|
0a7476 |
src/storage/storage_util.c | 6 ++----
|
|
|
0a7476 |
1 file changed, 2 insertions(+), 4 deletions(-)
|
|
|
0a7476 |
|
|
|
0a7476 |
diff --git a/src/storage/storage_util.c b/src/storage/storage_util.c
|
|
|
0a7476 |
index 19e6e0544b..54e778490d 100644
|
|
|
0a7476 |
--- a/src/storage/storage_util.c
|
|
|
0a7476 |
+++ b/src/storage/storage_util.c
|
|
|
0a7476 |
@@ -709,7 +709,6 @@ struct _virStorageBackendQemuImgInfo {
|
|
|
0a7476 |
int inputFormat;
|
|
|
0a7476 |
|
|
|
0a7476 |
char *secretAlias;
|
|
|
0a7476 |
- const char *secretPath;
|
|
|
0a7476 |
};
|
|
|
0a7476 |
|
|
|
0a7476 |
|
|
|
0a7476 |
@@ -1081,7 +1080,6 @@ virStorageBackendCreateQemuImgCmdFromVol(virStoragePoolObjPtr pool,
|
|
|
0a7476 |
.compat = vol->target.compat,
|
|
|
0a7476 |
.features = vol->target.features,
|
|
|
0a7476 |
.nocow = vol->target.nocow,
|
|
|
0a7476 |
- .secretPath = secretPath,
|
|
|
0a7476 |
.secretAlias = NULL,
|
|
|
0a7476 |
};
|
|
|
0a7476 |
virStorageEncryptionPtr enc = vol->target.encryption;
|
|
|
0a7476 |
@@ -1124,14 +1122,14 @@ virStorageBackendCreateQemuImgCmdFromVol(virStoragePoolObjPtr pool,
|
|
|
0a7476 |
virCommandAddArgList(cmd, "-b", info.backingPath, NULL);
|
|
|
0a7476 |
|
|
|
0a7476 |
if (enc) {
|
|
|
0a7476 |
- if (!info.secretPath) {
|
|
|
0a7476 |
+ if (!secretPath) {
|
|
|
0a7476 |
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
|
|
|
0a7476 |
_("path to secret data file is required"));
|
|
|
0a7476 |
goto error;
|
|
|
0a7476 |
}
|
|
|
0a7476 |
if (virAsprintf(&info.secretAlias, "%s_encrypt0", vol->name) < 0)
|
|
|
0a7476 |
goto error;
|
|
|
0a7476 |
- if (storageBackendCreateQemuImgSecretObject(cmd, info.secretPath,
|
|
|
0a7476 |
+ if (storageBackendCreateQemuImgSecretObject(cmd, secretPath,
|
|
|
0a7476 |
info.secretAlias) < 0)
|
|
|
0a7476 |
goto error;
|
|
|
0a7476 |
encinfo = &enc->encinfo;
|
|
|
0a7476 |
--
|
|
|
0a7476 |
2.21.0
|
|
|
0a7476 |
|