diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2011-06-20 18:40:32 +0930 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2011-06-20 11:18:35 +0200 |
commit | 4823262439bc6c1ce9fcce97ed472ad44e85cb77 (patch) | |
tree | e7ec18964e9790d52f0c6d14cd1ff63d421dfc72 /source3/lib/gencache.c | |
parent | a4993f647cfc5b8e0cf4405cc1d8815770837310 (diff) | |
download | samba-4823262439bc6c1ce9fcce97ed472ad44e85cb77.tar.gz samba-4823262439bc6c1ce9fcce97ed472ad44e85cb77.tar.bz2 samba-4823262439bc6c1ce9fcce97ed472ad44e85cb77.zip |
tdb2: #ifdef out TDB_ERR_NOLOCK and TDB_ERR_LOCK_TIMEOUT.
These don't exist in tdb2. The former is used in one weird place in
tdb1, and the latter not at all.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source3/lib/gencache.c')
-rw-r--r-- | source3/lib/gencache.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source3/lib/gencache.c b/source3/lib/gencache.c index 296f50ebae..c00cc115af 100644 --- a/source3/lib/gencache.c +++ b/source3/lib/gencache.c @@ -463,7 +463,12 @@ bool gencache_stabilize(void) res = tdb_transaction_start_nonblock(cache); if (res != 0) { - if (tdb_error(cache) == TDB_ERR_NOLOCK) { +#if BUILD_TDB2 + if (res == TDB_ERR_LOCK) +#else + if (tdb_error(cache) == TDB_ERR_NOLOCK) +#endif + { /* * Someone else already does the stabilize, * this does not have to be done twice |