summaryrefslogtreecommitdiff
path: root/source3/param
diff options
context:
space:
mode:
authorBo Yang <boyang@samba.org>2009-07-15 15:34:10 +0800
committerBo Yang <boyang@samba.org>2009-07-15 17:05:45 +0800
commit9ef6af73b319048fc6f3891573f0e10066dffee6 (patch)
tree078f7f4bc24089939e1b473fb5f3932f33db1a73 /source3/param
parent99c7ee3c9145b6187113ff29500b55a32320a9bc (diff)
downloadsamba-9ef6af73b319048fc6f3891573f0e10066dffee6.tar.gz
samba-9ef6af73b319048fc6f3891573f0e10066dffee6.tar.bz2
samba-9ef6af73b319048fc6f3891573f0e10066dffee6.zip
s3: Make smbd aware of permission change of usershare. Since usershare are relatively volatile and non-previledge users must disconnect from smbd and reconnect to it to make share permission in effect.
Diffstat (limited to 'source3/param')
-rw-r--r--source3/param/loadparm.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index 7e4371bf0b..7b4e363f1b 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -8727,6 +8727,17 @@ static int process_usershare_file(const char *dir_name, const char *file_name, i
}
/***************************************************************************
+Am I a usershare service?
+***************************************************************************/
+bool am_usershare(int iService)
+{
+ if (iService >= 0) {
+ return (ServicePtrs[iService]->usershare == USERSHARE_VALID);
+ }
+ return false;
+}
+
+/***************************************************************************
Checks if a usershare entry has been modified since last load.
***************************************************************************/