diff options
author | Stefan Metzmacher <metze@samba.org> | 2008-02-22 10:18:13 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2008-02-25 11:50:30 +0100 |
commit | 27e322bb4d5a25a2a1ebc5df36690590d86e3afd (patch) | |
tree | c849edf723e24edb1dc980810104153ac7eb6469 /source4/ntvfs/common/opendb_tdb.c | |
parent | 599901c139e99dca26f267439c14119e6c3f2092 (diff) | |
download | samba-27e322bb4d5a25a2a1ebc5df36690590d86e3afd.tar.gz samba-27e322bb4d5a25a2a1ebc5df36690590d86e3afd.tar.bz2 samba-27e322bb4d5a25a2a1ebc5df36690590d86e3afd.zip |
opendb: add odb_get_key() function to get the key back from a struct odb_lock
metze
(This used to be commit 11f35a2a4d383b506ced35ba06120f9531bac70c)
Diffstat (limited to 'source4/ntvfs/common/opendb_tdb.c')
-rw-r--r-- | source4/ntvfs/common/opendb_tdb.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source4/ntvfs/common/opendb_tdb.c b/source4/ntvfs/common/opendb_tdb.c index abd9ca708b..469cf28374 100644 --- a/source4/ntvfs/common/opendb_tdb.c +++ b/source4/ntvfs/common/opendb_tdb.c @@ -134,6 +134,12 @@ static struct odb_lock *odb_tdb_lock(TALLOC_CTX *mem_ctx, return lck; } +static DATA_BLOB odb_tdb_get_key(TALLOC_CTX *mem_ctx, struct odb_lock *lck) +{ + return data_blob_talloc(mem_ctx, lck->key.dptr, lck->key.dsize); +} + + /* determine if two odb_entry structures conflict @@ -609,6 +615,7 @@ static NTSTATUS odb_tdb_can_open(struct odb_lock *lck, static const struct opendb_ops opendb_tdb_ops = { .odb_init = odb_tdb_init, .odb_lock = odb_tdb_lock, + .odb_get_key = odb_tdb_get_key, .odb_open_file = odb_tdb_open_file, .odb_open_file_pending = odb_tdb_open_file_pending, .odb_close_file = odb_tdb_close_file, |