diff options
author | Andrew Tridgell <tridge@samba.org> | 2003-12-10 03:02:12 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2003-12-10 03:02:12 +0000 |
commit | 3c76426f2e343df2194825ae2e0ef84f4ad4c6ac (patch) | |
tree | b73a43828bf249b144cc1d2476ecdd778d5386f8 /source4/tdb/spinlock.h | |
parent | 303454cae1766ffd5b19bf24b259519303b7bc90 (diff) | |
download | samba-3c76426f2e343df2194825ae2e0ef84f4ad4c6ac.tar.gz samba-3c76426f2e343df2194825ae2e0ef84f4ad4c6ac.tar.bz2 samba-3c76426f2e343df2194825ae2e0ef84f4ad4c6ac.zip |
* removed some unused code
* updated tdb to latest version from Samba3
* removed some extraneous ';' in tdbutil.c (Thanks to Erlend Aasland
for pointing this out)
(This used to be commit f3eaf270e57d8d2e2157a6a36e260860c7f71c19)
Diffstat (limited to 'source4/tdb/spinlock.h')
-rw-r--r-- | source4/tdb/spinlock.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/source4/tdb/spinlock.h b/source4/tdb/spinlock.h index d6a2ac6eb8..967fe37457 100644 --- a/source4/tdb/spinlock.h +++ b/source4/tdb/spinlock.h @@ -1,7 +1,7 @@ #ifndef __SPINLOCK_H__ #define __SPINLOCK_H__ -#if HAVE_CONFIG_H +#ifdef HAVE_CONFIG_H #include <config.h> #endif @@ -39,6 +39,8 @@ int tdb_spinunlock(TDB_CONTEXT *tdb, int list, int rw_type); int tdb_create_rwlocks(int fd, unsigned int hash_size); int tdb_clear_spinlocks(TDB_CONTEXT *tdb); +#define TDB_SPINLOCK_SIZE(hash_size) (((hash_size) + 1) * sizeof(tdb_rwlock_t)) + #else /* !USE_SPINLOCKS */ #if 0 #define tdb_create_rwlocks(fd, hash_size) 0 @@ -50,6 +52,8 @@ int tdb_spinunlock(TDB_CONTEXT *tdb, int list, int rw_type); int tdb_create_rwlocks(int fd, unsigned int hash_size); #endif int tdb_clear_spinlocks(TDB_CONTEXT *tdb); +#define TDB_SPINLOCK_SIZE(hash_size) 0 + #endif #endif |