From bef92ebb257adda6634c559e0240ad4991840212 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 11 Nov 2006 18:07:51 +0000 Subject: [PATCH] r19669: set_share_security does not need a mem_ctx passed (This used to be commit 53eaa603eb84047263c27d57b8c0f5ce8e157189) --- source3/lib/sharesec.c | 2 +- source3/param/loadparm.c | 2 +- source3/rpc_server/srv_srvsvc_nt.c | 4 ++-- source3/utils/sharesec.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/source3/lib/sharesec.c b/source3/lib/sharesec.c index 81b383d1670..e3216aa4594 100644 --- a/source3/lib/sharesec.c +++ b/source3/lib/sharesec.c @@ -145,7 +145,7 @@ SEC_DESC *get_share_security( TALLOC_CTX *ctx, const char *servicename, Store a security descriptor in the share db. ********************************************************************/ -BOOL set_share_security(TALLOC_CTX *ctx, const char *share_name, SEC_DESC *psd) +BOOL set_share_security(const char *share_name, SEC_DESC *psd) { prs_struct ps; TALLOC_CTX *mem_ctx = NULL; diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index 68dd9d5a97a..cb9f8306b04 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -4608,7 +4608,7 @@ static int process_usershare_file(const char *dir_name, const char *file_name, i } /* Write the ACL of the new/modified share. */ - if (!set_share_security(ctx, service_name, psd)) { + if (!set_share_security(service_name, psd)) { DEBUG(0, ("process_usershare_file: Failed to set share " "security for user share %s\n", service_name )); diff --git a/source3/rpc_server/srv_srvsvc_nt.c b/source3/rpc_server/srv_srvsvc_nt.c index c4a6c1103eb..35938d087e2 100644 --- a/source3/rpc_server/srv_srvsvc_nt.c +++ b/source3/rpc_server/srv_srvsvc_nt.c @@ -1542,7 +1542,7 @@ WERROR _srvsvc_NetShareSetInfo(pipes_struct *p, const char *server_unc, const ch &sd_size); if (old_sd && !sec_desc_equal(old_sd, psd)) { - if (!set_share_security(p->mem_ctx, share_name, psd)) + if (!set_share_security(share_name, psd)) DEBUG(0,("_srv_net_share_set_info: Failed to change security info in share %s.\n", share_name )); } @@ -1691,7 +1691,7 @@ WERROR _srvsvc_NetShareAdd(pipes_struct *p, const char *server_unc, uint32_t lev return WERR_ACCESS_DENIED; if (psd) { - if (!set_share_security(p->mem_ctx, share_name, psd)) { + if (!set_share_security(share_name, psd)) { DEBUG(0,("_srv_net_share_add: Failed to add security info to share %s.\n", share_name )); } } diff --git a/source3/utils/sharesec.c b/source3/utils/sharesec.c index 5749cf2f555..11882ff07a4 100644 --- a/source3/utils/sharesec.c +++ b/source3/utils/sharesec.c @@ -402,7 +402,7 @@ int main(int argc, const char *argv[]) return -1; } - if ( !set_share_security( ctx, lp_servicename(snum), secdesc ) ) { + if ( !set_share_security( lp_servicename(snum), secdesc ) ) { fprintf( stderr, "Failed to store acl for share [%s]\n", sharename ); return 2; } -- 2.34.1