diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-10-07 17:58:48 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:31:13 -0500 |
commit | b5535567c11552ed675ecc489d440558f91f1d1d (patch) | |
tree | ff35ae380e846ae1eb7b944b81aa6572c9c636cb /source3/lib | |
parent | 3a14416dde836e3f6be57bcdfd63250f9df7f615 (diff) | |
download | samba-b5535567c11552ed675ecc489d440558f91f1d1d.tar.gz samba-b5535567c11552ed675ecc489d440558f91f1d1d.tar.bz2 samba-b5535567c11552ed675ecc489d440558f91f1d1d.zip |
r25564: Pass sharename to delete_share_security()
(This used to be commit d100bfffe2a503b8820889faedc6ed57100ca7af)
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/sharesec.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/source3/lib/sharesec.c b/source3/lib/sharesec.c index 258b121217..58e28e797d 100644 --- a/source3/lib/sharesec.c +++ b/source3/lib/sharesec.c @@ -197,18 +197,20 @@ BOOL set_share_security(const char *share_name, SEC_DESC *psd) Delete a security descriptor. ********************************************************************/ -BOOL delete_share_security(const struct share_params *params) +BOOL delete_share_security(const char *servicename) { TDB_DATA kbuf; - fstring key; + char *key; - slprintf(key, sizeof(key)-1, "SECDESC/%s", - lp_servicename(params->service)); + if (!(key = talloc_asprintf(talloc_tos(), "SECDESC/%s", + servicename))) { + return False; + } kbuf = string_term_tdb_data(key); if (tdb_trans_delete(share_tdb, kbuf) != 0) { - DEBUG(0,("delete_share_security: Failed to delete entry for share %s\n", - lp_servicename(params->service) )); + DEBUG(0, ("delete_share_security: Failed to delete entry for " + "share %s\n", servicename)); return False; } |