The argument (if not NULL) points to the file the domain is
restoring from. On QEMU command line this used to be '-incoming
$path', but we've switched to passing FD ages ago and thus this
argument is used only in AppArmor (which loads the profile on
domain start). Anyway, the argument does not refer to stdin,
rename it to 'incomingPath' then.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/security/security_apparmor.c | 8 ++++----
src/security/security_dac.c | 2 +-
src/security/security_driver.h | 2 +-
src/security/security_manager.c | 4 ++--
src/security/security_manager.h | 2 +-
src/security/security_nop.c | 2 +-
src/security/security_selinux.c | 2 +-
src/security/security_stack.c | 4 ++--
8 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/src/security/security_apparmor.c b/src/security/security_apparmor.c
index 583e872614..3f6a213b43 100644
--- a/src/security/security_apparmor.c
+++ b/src/security/security_apparmor.c
@@ -455,7 +455,7 @@ AppArmorGenSecurityLabel(virSecurityManagerPtr mgr G_GNUC_UNUSED,
static int
AppArmorSetSecurityAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr def,
- const char *stdin_path,
+ const char *incomingPath,
bool chardevStdioLogd G_GNUC_UNUSED,
bool migrated G_GNUC_UNUSED)
{
@@ -464,10 +464,10 @@ AppArmorSetSecurityAllLabel(virSecurityManagerPtr mgr,
if (!secdef || !secdef->relabel)
return 0;
- /* Reload the profile if stdin_path is specified. Note that
+ /* Reload the profile if incomingPath is specified. Note that
GenSecurityLabel() will have already been run. */
- if (stdin_path)
- return reload_profile(mgr, def, stdin_path, true);
+ if (incomingPath)
+ return reload_profile(mgr, def, incomingPath, true);
return 0;
}
diff --git a/src/security/security_dac.c b/src/security/security_dac.c
index 23fe351a32..dd701ef28b 100644
--- a/src/security/security_dac.c
+++ b/src/security/security_dac.c
@@ -2142,7 +2142,7 @@ virSecurityDACSetSysinfoLabel(virSecurityManagerPtr mgr,
static int
virSecurityDACSetAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr def,
- const char *stdin_path G_GNUC_UNUSED,
+ const char *incomingPath G_GNUC_UNUSED,
bool chardevStdioLogd,
bool migrated G_GNUC_UNUSED)
{
diff --git a/src/security/security_driver.h b/src/security/security_driver.h
index f0ba77032d..08cdf94598 100644
--- a/src/security/security_driver.h
+++ b/src/security/security_driver.h
@@ -82,7 +82,7 @@ typedef int (*virSecurityDomainReleaseLabel) (virSecurityManagerPtr
mgr,
virDomainDefPtr sec);
typedef int (*virSecurityDomainSetAllLabel) (virSecurityManagerPtr mgr,
virDomainDefPtr sec,
- const char *stdin_path,
+ const char *incomingPath,
bool chardevStdioLogd,
bool migrated);
typedef int (*virSecurityDomainRestoreAllLabel) (virSecurityManagerPtr mgr,
diff --git a/src/security/security_manager.c b/src/security/security_manager.c
index c073d8cc0d..9a242f9189 100644
--- a/src/security/security_manager.c
+++ b/src/security/security_manager.c
@@ -856,14 +856,14 @@ int virSecurityManagerCheckAllLabel(virSecurityManagerPtr mgr,
int
virSecurityManagerSetAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr vm,
- const char *stdin_path,
+ const char *incomingPath,
bool chardevStdioLogd,
bool migrated)
{
if (mgr->drv->domainSetSecurityAllLabel) {
int ret;
virObjectLock(mgr);
- ret = mgr->drv->domainSetSecurityAllLabel(mgr, vm, stdin_path,
+ ret = mgr->drv->domainSetSecurityAllLabel(mgr, vm, incomingPath,
chardevStdioLogd,
migrated);
virObjectUnlock(mgr);
diff --git a/src/security/security_manager.h b/src/security/security_manager.h
index 277151848e..1c9e166174 100644
--- a/src/security/security_manager.h
+++ b/src/security/security_manager.h
@@ -121,7 +121,7 @@ int virSecurityManagerCheckAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr sec);
int virSecurityManagerSetAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr sec,
- const char *stdin_path,
+ const char *incomingPath,
bool chardevStdioLogd,
bool migrated);
int virSecurityManagerRestoreAllLabel(virSecurityManagerPtr mgr,
diff --git a/src/security/security_nop.c b/src/security/security_nop.c
index de5da1ee1c..385a747f5b 100644
--- a/src/security/security_nop.c
+++ b/src/security/security_nop.c
@@ -119,7 +119,7 @@ virSecurityDomainReleaseLabelNop(virSecurityManagerPtr mgr
G_GNUC_UNUSED,
static int
virSecurityDomainSetAllLabelNop(virSecurityManagerPtr mgr G_GNUC_UNUSED,
virDomainDefPtr sec G_GNUC_UNUSED,
- const char *stdin_path G_GNUC_UNUSED,
+ const char *incomingPath G_GNUC_UNUSED,
bool chardevStdioLogd G_GNUC_UNUSED,
bool migrated G_GNUC_UNUSED)
{
diff --git a/src/security/security_selinux.c b/src/security/security_selinux.c
index 6b0581e4d9..52ff4fab0f 100644
--- a/src/security/security_selinux.c
+++ b/src/security/security_selinux.c
@@ -3169,7 +3169,7 @@ virSecuritySELinuxSetSysinfoLabel(virSecurityManagerPtr mgr,
static int
virSecuritySELinuxSetAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr def,
- const char *stdin_path G_GNUC_UNUSED,
+ const char *incomingPath G_GNUC_UNUSED,
bool chardevStdioLogd,
bool migrated G_GNUC_UNUSED)
{
diff --git a/src/security/security_stack.c b/src/security/security_stack.c
index 624431d4ef..2480c47f70 100644
--- a/src/security/security_stack.c
+++ b/src/security/security_stack.c
@@ -341,7 +341,7 @@ virSecurityStackRestoreHostdevLabel(virSecurityManagerPtr mgr,
static int
virSecurityStackSetAllLabel(virSecurityManagerPtr mgr,
virDomainDefPtr vm,
- const char *stdin_path,
+ const char *incomingPath,
bool chardevStdioLogd,
bool migrated)
{
@@ -350,7 +350,7 @@ virSecurityStackSetAllLabel(virSecurityManagerPtr mgr,
for (; item; item = item->next) {
if (virSecurityManagerSetAllLabel(item->securityManager, vm,
- stdin_path, chardevStdioLogd,
+ incomingPath, chardevStdioLogd,
migrated) < 0)
goto rollback;
}
--
2.26.2