Change in vdsm[master]: net: ifcfg uses chown to change the uid only
edwardh at redhat.com
edwardh at redhat.com
Sun Jan 10 14:14:45 UTC 2016
Edward Haas has uploaded a new change for review.
Change subject: net: ifcfg uses chown to change the uid only
......................................................................
net: ifcfg uses chown to change the uid only
chown() gid value should be set to -1 if there is no intention to change
it. A value of 0 refers to the root group.
Change-Id: If857d08e566ebc1a6cf648f418a3328f723c239b
Signed-off-by: Edward Haas <edwardh at redhat.com>
---
M lib/vdsm/network/configurators/ifcfg.py
1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/98/51598/1
diff --git a/lib/vdsm/network/configurators/ifcfg.py b/lib/vdsm/network/configurators/ifcfg.py
index 0532da5..33d288f 100644
--- a/lib/vdsm/network/configurators/ifcfg.py
+++ b/lib/vdsm/network/configurators/ifcfg.py
@@ -314,11 +314,11 @@
# make directory (if it doesn't exist) and assign it to vdsm
if not os.path.exists(dirName):
os.makedirs(dirName)
- os.chown(dirName, vdsm_uid, 0)
+ os.chown(dirName, vdsm_uid, -1)
with open(backup, 'w') as backupFile:
backupFile.write(content)
- os.chown(backup, vdsm_uid, 0)
+ os.chown(backup, vdsm_uid, -1)
logging.debug("Persistently backed up %s "
"(until next 'set safe config')", backup)
--
To view, visit https://gerrit.ovirt.org/51598
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: If857d08e566ebc1a6cf648f418a3328f723c239b
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Edward Haas <edwardh at redhat.com>
More information about the vdsm-patches
mailing list