diff options
author | Jeremy Allison <jra@samba.org> | 2001-04-09 20:12:53 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-04-09 20:12:53 +0000 |
commit | e796a35a8bf677b25ff733ff4466e54226b7e461 (patch) | |
tree | 67947907319dc0845826f428e4d67107769523c3 | |
parent | 7130bb0dcf6194e7098a4d81c6149d810179fb7c (diff) | |
download | samba-e796a35a8bf677b25ff733ff4466e54226b7e461.tar.gz samba-e796a35a8bf677b25ff733ff4466e54226b7e461.tar.bz2 samba-e796a35a8bf677b25ff733ff4466e54226b7e461.zip |
Removed "read only" arg as it isn't useful.
Jeremy.
(This used to be commit 6b75d79c4bcfb8333aaf1ed61cf8bd022e498f75)
-rw-r--r-- | source3/rpc_server/srv_srvsvc_nt.c | 35 |
1 files changed, 2 insertions, 33 deletions
diff --git a/source3/rpc_server/srv_srvsvc_nt.c b/source3/rpc_server/srv_srvsvc_nt.c index 3b0bb352fe..b3a5d1a901 100644 --- a/source3/rpc_server/srv_srvsvc_nt.c +++ b/source3/rpc_server/srv_srvsvc_nt.c @@ -252,33 +252,6 @@ static BOOL delete_share_security(int snum) } /******************************************************************* - Does this security descriptor map to a read only share ? -********************************************************************/ - -static BOOL read_only_share_sd(SEC_DESC *psd) -{ - int i; - SEC_ACL *ps_dacl = NULL; - - if (!psd) - return True; - - ps_dacl = psd->dacl; - if (!ps_dacl) - return True; - - for (i = 0; i < ps_dacl->num_aces; i++) { - SEC_ACE *psa = &ps_dacl->ace[i]; - - if (psa->type == SEC_ACE_TYPE_ACCESS_ALLOWED && - psa->info.mask & FILE_WRITE_DATA) - return False; - } - - return True; -} - -/******************************************************************* Map any generic bits to file specific bits. ********************************************************************/ @@ -1355,7 +1328,6 @@ uint32 _srv_net_share_add(pipes_struct *p, SRV_Q_NET_SHARE_ADD *q_u, SRV_R_NET_S int snum; int ret; char *ptr; - BOOL read_only = False; SEC_DESC *psd = NULL; DEBUG(5,("_srv_net_share_add: %d\n", __LINE__)); @@ -1383,7 +1355,6 @@ uint32 _srv_net_share_add(pipes_struct *p, SRV_Q_NET_SHARE_ADD *q_u, SRV_R_NET_S unistr2_to_ascii(comment, &q_u->info.share.info2.info_2_str.uni_remark, sizeof(share_name)); unistr2_to_ascii(pathname, &q_u->info.share.info2.info_2_str.uni_path, sizeof(share_name)); type = q_u->info.share.info2.info_2.type; - read_only = False; /* No SD means "Everyone full access. */ break; case 502: unistr2_to_ascii(share_name, &q_u->info.share.info502.info_502_str.uni_netname, sizeof(share_name)); @@ -1392,7 +1363,6 @@ uint32 _srv_net_share_add(pipes_struct *p, SRV_Q_NET_SHARE_ADD *q_u, SRV_R_NET_S type = q_u->info.share.info502.info_502.type; psd = q_u->info.share.info502.info_502_str.sd; map_generic_share_sd_bits(psd); - read_only = read_only_share_sd(psd); break; case 1005: /* DFS only level. */ @@ -1421,9 +1391,8 @@ uint32 _srv_net_share_add(pipes_struct *p, SRV_Q_NET_SHARE_ADD *q_u, SRV_R_NET_S string_replace(ptr, '"', ' '); string_replace(comment, '"', ' '); - slprintf(command, sizeof(command)-1, "%s \"%s\" \"%s\" \"%s\" \"%s\"", - lp_add_share_cmd(), share_name, ptr, comment, - read_only ? "read only = yes" : "read only = no" ); + slprintf(command, sizeof(command)-1, "%s \"%s\" \"%s\" \"%s\"", + lp_add_share_cmd(), share_name, ptr, comment); dos_to_unix(command, True); /* Convert to unix-codepage */ DEBUG(10,("_srv_net_share_add: Running [%s]\n", command )); |