diff options
author | Csaba Henk <csaba@redhat.com> | 2012-02-29 10:21:03 +0100 |
---|---|---|
committer | Vijay Bellur <vijay@gluster.com> | 2012-03-05 07:52:54 -0800 |
commit | 5b9d47a3a39fac39e3fbccd4083f2f45c9ce5b49 (patch) | |
tree | 357901d5a535fb9af4f1c8f326649b81e867fac0 /xlators/features/marker/utils/syncdaemon/syncdutils.py | |
parent | eb3bab1c6d391131cdff48a458fbfec2f53d7c6c (diff) |
geo-rep / syncdaemon: determine suitable xattr namespace based on privilege
Change-Id: I91fe16d7e5e4c21f138eab4ee0b9334aec40e41b
BUG: 765433
Signed-off-by: Csaba Henk <csaba@redhat.com>
Reviewed-on: http://review.gluster.com/2838
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Venky Shankar <vshankar@redhat.com>
Diffstat (limited to 'xlators/features/marker/utils/syncdaemon/syncdutils.py')
-rw-r--r-- | xlators/features/marker/utils/syncdaemon/syncdutils.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/xlators/features/marker/utils/syncdaemon/syncdutils.py b/xlators/features/marker/utils/syncdaemon/syncdutils.py index b91b328b9..11c2063b7 100644 --- a/xlators/features/marker/utils/syncdaemon/syncdutils.py +++ b/xlators/features/marker/utils/syncdaemon/syncdutils.py @@ -225,6 +225,9 @@ def getusername(uid = None): uid = os.geteuid() return pwd.getpwuid(uid).pw_name +def privileged(): + return os.geteuid() == 0 + def boolify(s): """ Generic string to boolean converter |