mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
security: Drop virSecurity(DAC|SELinux)SetImageLabelRelative()
The single caller for each function passes the same value for @src and @parent, which means that we don't really need the additional API. Signed-off-by: Andrea Bolognani <abologna@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Stefan Berger <stefanb@linux.ibm.com>
This commit is contained in:
parent
94028ebf48
commit
8ca0005ec6
@ -939,12 +939,12 @@ virSecurityDACSetImageLabelInternal(virSecurityManager *mgr,
|
||||
|
||||
|
||||
static int
|
||||
virSecurityDACSetImageLabelRelative(virSecurityManager *mgr,
|
||||
virSecurityDACSetImageLabel(virSecurityManager *mgr,
|
||||
virDomainDef *def,
|
||||
virStorageSource *src,
|
||||
virStorageSource *parent,
|
||||
virSecurityDomainImageLabelFlags flags)
|
||||
{
|
||||
virStorageSource *parent = src;
|
||||
virStorageSource *n;
|
||||
|
||||
for (n = src; virStorageSourceIsBacking(n); n = n->backingStore) {
|
||||
@ -962,15 +962,6 @@ virSecurityDACSetImageLabelRelative(virSecurityManager *mgr,
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int
|
||||
virSecurityDACSetImageLabel(virSecurityManager *mgr,
|
||||
virDomainDef *def,
|
||||
virStorageSource *src,
|
||||
virSecurityDomainImageLabelFlags flags)
|
||||
{
|
||||
return virSecurityDACSetImageLabelRelative(mgr, def, src, src, flags);
|
||||
}
|
||||
|
||||
static int
|
||||
virSecurityDACRestoreImageLabelInt(virSecurityManager *mgr,
|
||||
virDomainDef *def,
|
||||
|
@ -1980,12 +1980,12 @@ virSecuritySELinuxSetImageLabelInternal(virSecurityManager *mgr,
|
||||
|
||||
|
||||
static int
|
||||
virSecuritySELinuxSetImageLabelRelative(virSecurityManager *mgr,
|
||||
virSecuritySELinuxSetImageLabel(virSecurityManager *mgr,
|
||||
virDomainDef *def,
|
||||
virStorageSource *src,
|
||||
virStorageSource *parent,
|
||||
virSecurityDomainImageLabelFlags flags)
|
||||
{
|
||||
virStorageSource *parent = src;
|
||||
virStorageSource *n;
|
||||
|
||||
for (n = src; virStorageSourceIsBacking(n); n = n->backingStore) {
|
||||
@ -2004,15 +2004,6 @@ virSecuritySELinuxSetImageLabelRelative(virSecurityManager *mgr,
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
virSecuritySELinuxSetImageLabel(virSecurityManager *mgr,
|
||||
virDomainDef *def,
|
||||
virStorageSource *src,
|
||||
virSecurityDomainImageLabelFlags flags)
|
||||
{
|
||||
return virSecuritySELinuxSetImageLabelRelative(mgr, def, src, src, flags);
|
||||
}
|
||||
|
||||
struct virSecuritySELinuxMoveImageMetadataData {
|
||||
virSecurityManager *mgr;
|
||||
const char *src;
|
||||
|
Loading…
Reference in New Issue
Block a user