aboutsummaryrefslogtreecommitdiffstats
path: root/mount.cifs.c
diff options
context:
space:
mode:
authorJeff Layton <jlayton@samba.org>2012-04-20 07:59:17 -0400
committerJeff Layton <jlayton@samba.org>2012-04-20 07:59:17 -0400
commita91fb0671273e4ef9079ee7860574c460aa94a51 (patch)
tree89c1d88bba5153c31c46bbc9b758409214dbc1a4 /mount.cifs.c
parent0aa12de5c1565d56a240d7b0dd814316f4ea81f3 (diff)
downloadcifs-utils-a91fb0671273e4ef9079ee7860574c460aa94a51.tar.gz
cifs-utils-a91fb0671273e4ef9079ee7860574c460aa94a51.tar.xz
cifs-utils-a91fb0671273e4ef9079ee7860574c460aa94a51.zip
mount.cifs: remove unnecessary getuid() check in libcap version of toggle_dac_capability
I'm not sure what I was thinking when I added that check in, but it's been there since the inception. We shouldn't care at all what the real uid is when we call toggle_dac_capability and indeed we don't care with the libcap-ng version. Remove that check. Signed-off-by: Jeff Layton <jlayton@samba.org>
Diffstat (limited to 'mount.cifs.c')
-rw-r--r--mount.cifs.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/mount.cifs.c b/mount.cifs.c
index 06715dd..c90ce3e 100644
--- a/mount.cifs.c
+++ b/mount.cifs.c
@@ -552,9 +552,6 @@ toggle_dac_capability(int writable, int enable)
cap_t caps;
cap_value_t capability = writable ? CAP_DAC_OVERRIDE : CAP_DAC_READ_SEARCH;
- if (getuid() != 0)
- return 0;
-
caps = cap_get_proc();
if (caps == NULL) {
fprintf(stderr, "Unable to get current capability set: %s\n",