summaryrefslogtreecommitdiffstats
path: root/source3/passdb
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2011-06-20 18:40:33 +0930
committerRusty Russell <rusty@rustcorp.com.au>2011-06-20 11:18:35 +0200
commitd925b327f4703cc141c0a7f3eec912dba8440880 (patch)
treea9d190b375dcae03863591d8f31688dc949fa3eb /source3/passdb
parentca1936fbb26af0ee8d0421ae6a4e07a0f62311d9 (diff)
downloadsamba-d925b327f4703cc141c0a7f3eec912dba8440880.tar.gz
samba-d925b327f4703cc141c0a7f3eec912dba8440880.tar.xz
samba-d925b327f4703cc141c0a7f3eec912dba8440880.zip
tdb_compat: Higher level API fixes.
My previous patches fixed up all direct TDB callers, but there are a few utility functions and the db_context functions which are still using the old -1 / 0 return codes. It's clearer to fix up all the callers of these too, so everywhere is consistent: non-zero means an error. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source3/passdb')
-rw-r--r--source3/passdb/login_cache.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/passdb/login_cache.c b/source3/passdb/login_cache.c
index 629f8a7d5e..a53fe5b24f 100644
--- a/source3/passdb/login_cache.c
+++ b/source3/passdb/login_cache.c
@@ -59,10 +59,10 @@ bool login_cache_init(void)
bool login_cache_shutdown(void)
{
- /* tdb_close routine returns -1 on error */
+ /* tdb_close routine returns non-zero on error */
if (!cache) return False;
DEBUG(5, ("Closing cache file\n"));
- return tdb_close(cache) != -1;
+ return tdb_close(cache) == 0;
}
/* if we can't read the cache, oh well, no need to return anything */