diff options
author | Volker Lendecke <vl@samba.org> | 2016-09-13 12:25:14 +0200 |
---|---|---|
committer | Ralph Boehme <slow@samba.org> | 2017-07-25 17:43:16 +0200 |
commit | 10c59f5b2052a5d3edf69444aaf46b05d2cd3a31 (patch) | |
tree | 797939a80dd607028ffedf9ddf2f47365d741622 /lib | |
parent | 09915bf8e5d59969cab7de0e75fd327046cffd8d (diff) | |
download | samba-10c59f5b2052a5d3edf69444aaf46b05d2cd3a31.tar.gz |
dbwrap: Add dbwrap_record_storev
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/dbwrap/dbwrap.c | 10 | ||||
-rw-r--r-- | lib/dbwrap/dbwrap.h | 2 |
2 files changed, 10 insertions, 2 deletions
diff --git a/lib/dbwrap/dbwrap.c b/lib/dbwrap/dbwrap.c index 85f2213082f..713c4203996 100644 --- a/lib/dbwrap/dbwrap.c +++ b/lib/dbwrap/dbwrap.c @@ -82,17 +82,23 @@ TDB_DATA dbwrap_record_get_value(const struct db_record *rec) return rec->value; } -NTSTATUS dbwrap_record_store(struct db_record *rec, TDB_DATA data, int flags) +NTSTATUS dbwrap_record_storev(struct db_record *rec, + const TDB_DATA *dbufs, int num_dbufs, int flags) { NTSTATUS status; - status = rec->storev(rec, &data, 1, flags); + status = rec->storev(rec, dbufs, num_dbufs, flags); if (!NT_STATUS_IS_OK(status)) { return status; } return NT_STATUS_OK; } +NTSTATUS dbwrap_record_store(struct db_record *rec, TDB_DATA data, int flags) +{ + return dbwrap_record_storev(rec, &data, 1, flags); +} + NTSTATUS dbwrap_record_delete(struct db_record *rec) { NTSTATUS status; diff --git a/lib/dbwrap/dbwrap.h b/lib/dbwrap/dbwrap.h index e34b2ab3882..04e179e75e6 100644 --- a/lib/dbwrap/dbwrap.h +++ b/lib/dbwrap/dbwrap.h @@ -72,6 +72,8 @@ enum dbwrap_req_state { TDB_DATA dbwrap_record_get_key(const struct db_record *rec); TDB_DATA dbwrap_record_get_value(const struct db_record *rec); NTSTATUS dbwrap_record_store(struct db_record *rec, TDB_DATA data, int flags); +NTSTATUS dbwrap_record_storev(struct db_record *rec, + const TDB_DATA *dbufs, int num_dbufs, int flags); NTSTATUS dbwrap_record_delete(struct db_record *rec); struct db_record *dbwrap_fetch_locked(struct db_context *db, TALLOC_CTX *mem_ctx, |