diff options
author | Michael Adam <obnox@samba.org> | 2011-11-11 00:49:11 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2011-11-29 18:20:06 +0100 |
commit | efb993b686e397e06ba647089535c92ec08c4345 (patch) | |
tree | 470e5e6cd40991409f66e8ddcdac88cfce68fceb /source3/lib/dbwrap/dbwrap_private.h | |
parent | 819ca3b697e1b396b83308341cf81c19362c2626 (diff) | |
download | samba-efb993b686e397e06ba647089535c92ec08c4345.tar.gz samba-efb993b686e397e06ba647089535c92ec08c4345.tar.bz2 samba-efb993b686e397e06ba647089535c92ec08c4345.zip |
s3:dbwrap: turn the fetch dbwrap method to NTSTATUS return code.
This implement more correct NTSTATUS handling inside the backends.
This ensures that data.dptr != NULL if return code is NT_STATUS_OK.
Diffstat (limited to 'source3/lib/dbwrap/dbwrap_private.h')
-rw-r--r-- | source3/lib/dbwrap/dbwrap_private.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/lib/dbwrap/dbwrap_private.h b/source3/lib/dbwrap/dbwrap_private.h index 0a8581a91b..e7bd480cbb 100644 --- a/source3/lib/dbwrap/dbwrap_private.h +++ b/source3/lib/dbwrap/dbwrap_private.h @@ -34,8 +34,8 @@ struct db_context { struct db_record *(*fetch_locked)(struct db_context *db, TALLOC_CTX *mem_ctx, TDB_DATA key); - int (*fetch)(struct db_context *db, TALLOC_CTX *mem_ctx, - TDB_DATA key, TDB_DATA *data); + NTSTATUS (*fetch)(struct db_context *db, TALLOC_CTX *mem_ctx, + TDB_DATA key, TDB_DATA *data); int (*traverse)(struct db_context *db, int (*f)(struct db_record *rec, void *private_data), @@ -59,8 +59,8 @@ struct db_context { bool persistent; }; -int dbwrap_fallback_fetch(struct db_context *db, TALLOC_CTX *mem_ctx, - TDB_DATA key, TDB_DATA *data); +NTSTATUS dbwrap_fallback_fetch(struct db_context *db, TALLOC_CTX *mem_ctx, + TDB_DATA key, TDB_DATA *data); int dbwrap_fallback_parse_record(struct db_context *db, TDB_DATA key, |