summaryrefslogtreecommitdiff
path: root/lib/tdb2/private.h
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2012-06-18 22:30:26 +0930
committerRusty Russell <rusty@rustcorp.com.au>2012-06-19 05:38:05 +0200
commitc3dcdf08f3472748c9e7984488398064abcd454a (patch)
tree3c7ea8afbb00cfae914bd7011d0a4b1321764133 /lib/tdb2/private.h
parentcab6e116786641e28747de3f70c8cd89ba17673f (diff)
downloadsamba-c3dcdf08f3472748c9e7984488398064abcd454a.tar.gz
samba-c3dcdf08f3472748c9e7984488398064abcd454a.tar.bz2
samba-c3dcdf08f3472748c9e7984488398064abcd454a.zip
TDB2: more internal cleanups after TDB1 compatibility removal.
This eliminates the separate tdb2 substructure, and makes some tdb1-required functions static. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'lib/tdb2/private.h')
-rw-r--r--lib/tdb2/private.h44
1 files changed, 11 insertions, 33 deletions
diff --git a/lib/tdb2/private.h b/lib/tdb2/private.h
index da0454b4de..8c917a70b2 100644
--- a/lib/tdb2/private.h
+++ b/lib/tdb2/private.h
@@ -547,25 +547,6 @@ bool tdb_has_expansion_lock(struct tdb_context *tdb);
/* If it needs recovery, grab all the locks and do it. */
enum TDB_ERROR tdb_lock_and_recover(struct tdb_context *tdb);
-/* Byte-range lock wrappers for TDB1 to access. */
-enum TDB_ERROR tdb_brlock(struct tdb_context *tdb,
- int rw_type, tdb_off_t offset, tdb_off_t len,
- enum tdb_lock_flags flags);
-
-enum TDB_ERROR tdb_brunlock(struct tdb_context *tdb,
- int rw_type, tdb_off_t offset, size_t len);
-
-enum TDB_ERROR tdb_nest_lock(struct tdb_context *tdb,
- tdb_off_t offset, int ltype,
- enum tdb_lock_flags flags);
-
-enum TDB_ERROR tdb_nest_unlock(struct tdb_context *tdb,
- tdb_off_t off, int ltype);
-
-enum TDB_ERROR tdb_lock_gradual(struct tdb_context *tdb,
- int ltype, enum tdb_lock_flags flags,
- tdb_off_t off, tdb_off_t len);
-
/* Default lock and unlock functions. */
int tdb_fcntl_lock(int fd, int rw, off_t off, off_t len, bool waitflag, void *);
int tdb_fcntl_unlock(int fd, int rw, off_t off, off_t len, void *);
@@ -618,24 +599,21 @@ struct tdb_context {
/* Last error we returned. */
enum TDB_ERROR last_error;
- struct {
-
- /* Are we accessing directly? (debugging check). */
- int direct_access;
+ /* Are we accessing directly? (debugging check). */
+ int direct_access;
- /* Set if we are in a transaction. */
- struct tdb_transaction *transaction;
+ /* Set if we are in a transaction. */
+ struct tdb_transaction *transaction;
- /* What free table are we using? */
- tdb_off_t ftable_off;
- unsigned int ftable;
+ /* What free table are we using? */
+ tdb_off_t ftable_off;
+ unsigned int ftable;
- /* IO methods: changes for transactions. */
- const struct tdb_methods *io;
+ /* IO methods: changes for transactions. */
+ const struct tdb_methods *io;
- /* Direct access information */
- struct tdb_access_hdr *access;
- } tdb2;
+ /* Direct access information */
+ struct tdb_access_hdr *access;
};
/* tdb.c: */