diff options
author | Volker Lendecke <vl@samba.org> | 2011-12-08 16:46:09 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2011-12-15 16:00:47 +0100 |
commit | f6d8f7440c4f7e25574045a4e42a770d48d4c43d (patch) | |
tree | dac74bad111c2ac945dbfd2bb180c00a4c395f90 /source3/lib/dbwrap/dbwrap_rbt.c | |
parent | b5d056ca231f67b4c6fd608ecbe6f83f1823a33b (diff) | |
download | samba-f6d8f7440c4f7e25574045a4e42a770d48d4c43d.tar.gz samba-f6d8f7440c4f7e25574045a4e42a770d48d4c43d.tar.bz2 samba-f6d8f7440c4f7e25574045a4e42a770d48d4c43d.zip |
s3-dbwrap: Remove the "fetch" db_context callback
Signed-off-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'source3/lib/dbwrap/dbwrap_rbt.c')
-rw-r--r-- | source3/lib/dbwrap/dbwrap_rbt.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/source3/lib/dbwrap/dbwrap_rbt.c b/source3/lib/dbwrap/dbwrap_rbt.c index 09bc210f9e..2460418d1d 100644 --- a/source3/lib/dbwrap/dbwrap_rbt.c +++ b/source3/lib/dbwrap/dbwrap_rbt.c @@ -345,29 +345,6 @@ static NTSTATUS db_rbt_parse_record(struct db_context *db, TDB_DATA key, return NT_STATUS_OK; } -static NTSTATUS db_rbt_fetch(struct db_context *db, TALLOC_CTX *mem_ctx, - TDB_DATA key, TDB_DATA *data) -{ - uint8_t *result; - struct db_rbt_search_result res; - - bool found = db_rbt_search_internal(db, key, &res); - - if (!found) { - *data = tdb_null; - return NT_STATUS_NOT_FOUND; - } - - result = (uint8_t*)talloc_memdup(mem_ctx, res.val.dptr, res.val.dsize); - if (result == NULL) { - return NT_STATUS_NO_MEMORY; - } - - data->dptr = result; - data->dsize = res.val.dsize; - return NT_STATUS_OK; -} - static int db_rbt_traverse_internal(struct rb_node *n, int (*f)(struct db_record *db, void *private_data), @@ -449,7 +426,6 @@ struct db_context *db_open_rbt(TALLOC_CTX *mem_ctx) } result->fetch_locked = db_rbt_fetch_locked; - result->fetch = db_rbt_fetch; result->traverse = db_rbt_traverse; result->traverse_read = db_rbt_traverse; result->get_seqnum = db_rbt_get_seqnum; |