|
|
fbe740 |
From c671c037d06c761708374dba1b7e4ed4041fe9fb Mon Sep 17 00:00:00 2001
|
|
|
fbe740 |
Message-Id: <c671c037d06c761708374dba1b7e4ed4041fe9fb@dist-git>
|
|
|
fbe740 |
From: Peter Krempa <pkrempa@redhat.com>
|
|
|
fbe740 |
Date: Fri, 20 Mar 2020 10:28:51 +0100
|
|
|
fbe740 |
Subject: [PATCH] virSecretLookupDefCopy: Remove return value
|
|
|
fbe740 |
MIME-Version: 1.0
|
|
|
fbe740 |
Content-Type: text/plain; charset=UTF-8
|
|
|
fbe740 |
Content-Transfer-Encoding: 8bit
|
|
|
fbe740 |
|
|
|
fbe740 |
The function always returns succes so there's no need for a return
|
|
|
fbe740 |
value.
|
|
|
fbe740 |
|
|
|
fbe740 |
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
|
|
|
fbe740 |
Reviewed-by: Ján Tomko <jtomko@redhat.com>
|
|
|
fbe740 |
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
|
|
|
fbe740 |
(cherry picked from commit 02f909b8a6ad8c271693fed9ceab606f0dda2294)
|
|
|
fbe740 |
|
|
|
fbe740 |
https://bugzilla.redhat.com/show_bug.cgi?id=1814923
|
|
|
fbe740 |
Message-Id: <a2f47ac4171ea9eaf3fbee12f22670ff10a1b98c.1584696274.git.pkrempa@redhat.com>
|
|
|
fbe740 |
Reviewed-by: Ján Tomko <jtomko@redhat.com>
|
|
|
fbe740 |
---
|
|
|
fbe740 |
src/util/virsecret.c | 3 +--
|
|
|
fbe740 |
src/util/virsecret.h | 4 ++--
|
|
|
fbe740 |
src/util/virstoragefile.c | 3 +--
|
|
|
fbe740 |
3 files changed, 4 insertions(+), 6 deletions(-)
|
|
|
fbe740 |
|
|
|
fbe740 |
diff --git a/src/util/virsecret.c b/src/util/virsecret.c
|
|
|
fbe740 |
index 174ce544c0..167ad24fdf 100644
|
|
|
fbe740 |
--- a/src/util/virsecret.c
|
|
|
fbe740 |
+++ b/src/util/virsecret.c
|
|
|
fbe740 |
@@ -47,7 +47,7 @@ virSecretLookupDefClear(virSecretLookupTypeDefPtr def)
|
|
|
fbe740 |
}
|
|
|
fbe740 |
|
|
|
fbe740 |
|
|
|
fbe740 |
-int
|
|
|
fbe740 |
+void
|
|
|
fbe740 |
virSecretLookupDefCopy(virSecretLookupTypeDefPtr dst,
|
|
|
fbe740 |
const virSecretLookupTypeDef *src)
|
|
|
fbe740 |
{
|
|
|
fbe740 |
@@ -57,7 +57,6 @@ virSecretLookupDefCopy(virSecretLookupTypeDefPtr dst,
|
|
|
fbe740 |
} else if (dst->type == VIR_SECRET_LOOKUP_TYPE_USAGE) {
|
|
|
fbe740 |
dst->u.usage = g_strdup(src->u.usage);
|
|
|
fbe740 |
}
|
|
|
fbe740 |
- return 0;
|
|
|
fbe740 |
}
|
|
|
fbe740 |
|
|
|
fbe740 |
|
|
|
fbe740 |
diff --git a/src/util/virsecret.h b/src/util/virsecret.h
|
|
|
fbe740 |
index 8bc8a24e0f..780b5761f4 100644
|
|
|
fbe740 |
--- a/src/util/virsecret.h
|
|
|
fbe740 |
+++ b/src/util/virsecret.h
|
|
|
fbe740 |
@@ -49,8 +49,8 @@ struct _virSecretLookupTypeDef {
|
|
|
fbe740 |
};
|
|
|
fbe740 |
|
|
|
fbe740 |
void virSecretLookupDefClear(virSecretLookupTypeDefPtr def);
|
|
|
fbe740 |
-int virSecretLookupDefCopy(virSecretLookupTypeDefPtr dst,
|
|
|
fbe740 |
- const virSecretLookupTypeDef *src);
|
|
|
fbe740 |
+void virSecretLookupDefCopy(virSecretLookupTypeDefPtr dst,
|
|
|
fbe740 |
+ const virSecretLookupTypeDef *src);
|
|
|
fbe740 |
int virSecretLookupParseSecret(xmlNodePtr secretnode,
|
|
|
fbe740 |
virSecretLookupTypeDefPtr def);
|
|
|
fbe740 |
void virSecretLookupFormatSecret(virBufferPtr buf,
|
|
|
fbe740 |
diff --git a/src/util/virstoragefile.c b/src/util/virstoragefile.c
|
|
|
fbe740 |
index ce126f5cba..fa37840532 100644
|
|
|
fbe740 |
--- a/src/util/virstoragefile.c
|
|
|
fbe740 |
+++ b/src/util/virstoragefile.c
|
|
|
fbe740 |
@@ -1792,8 +1792,7 @@ virStorageAuthDefCopy(const virStorageAuthDef *src)
|
|
|
fbe740 |
authdef->secrettype = g_strdup(src->secrettype);
|
|
|
fbe740 |
authdef->authType = src->authType;
|
|
|
fbe740 |
|
|
|
fbe740 |
- if (virSecretLookupDefCopy(&authdef->seclookupdef, &src->seclookupdef) < 0)
|
|
|
fbe740 |
- return NULL;
|
|
|
fbe740 |
+ virSecretLookupDefCopy(&authdef->seclookupdef, &src->seclookupdef);
|
|
|
fbe740 |
|
|
|
fbe740 |
return g_steal_pointer(&authdef);
|
|
|
fbe740 |
}
|
|
|
fbe740 |
--
|
|
|
fbe740 |
2.25.1
|
|
|
fbe740 |
|