diff options
author | Michael Adam <obnox@samba.org> | 2011-08-24 15:36:31 +0200 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2011-10-11 14:17:57 +0200 |
commit | 4cb75bdbb1b2e9c40a31992e1ac23125098b2d42 (patch) | |
tree | bb7d85502bd9d26bff0f230dbd030b8efe931a87 | |
parent | ceb9f572abda526e01d9b5f35158464768119c96 (diff) | |
download | samba-4cb75bdbb1b2e9c40a31992e1ac23125098b2d42.tar.gz samba-4cb75bdbb1b2e9c40a31992e1ac23125098b2d42.tar.bz2 samba-4cb75bdbb1b2e9c40a31992e1ac23125098b2d42.zip |
s3:vfs: convert nfs4_acls sidmap db code to use dbwrap_wrapper functions
Avoid direct use of the db_record and db_context structs.
-rw-r--r-- | source3/modules/nfs4_acls.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/modules/nfs4_acls.c b/source3/modules/nfs4_acls.c index 05bad5d30e..b4715af2ed 100644 --- a/source3/modules/nfs4_acls.c +++ b/source3/modules/nfs4_acls.c @@ -576,6 +576,7 @@ static bool nfs4_map_sid(smbacl4_vfs_params *params, const struct dom_sid *src, { static struct db_context *mapping_db = NULL; TDB_DATA data; + NTSTATUS status; if (mapping_db == NULL) { const char *dbname = lp_parm_const_string( @@ -599,9 +600,10 @@ static bool nfs4_map_sid(smbacl4_vfs_params *params, const struct dom_sid *src, } } - if (mapping_db->fetch(mapping_db, NULL, + status = dbwrap_fetch(mapping_db, NULL, string_term_tdb_data(sid_string_tos(src)), - &data) != 0) { + &data); + if (!NT_STATUS_IS_OK(status)) { DEBUG(10, ("could not find mapping for SID %s\n", sid_string_dbg(src))); return False; |