diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2011-06-20 18:40:31 +0930 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2011-06-20 11:18:35 +0200 |
commit | 5a7874e119acbc80410b2f2c1847371236c22a56 (patch) | |
tree | 86a351bdb3abfa3dc78c106f123e508e19a56fe9 /source3/rpc_server/srvsvc | |
parent | 9850f256337d70401d962bb1f6d5b834a221358d (diff) | |
download | samba-5a7874e119acbc80410b2f2c1847371236c22a56.tar.gz samba-5a7874e119acbc80410b2f2c1847371236c22a56.tar.bz2 samba-5a7874e119acbc80410b2f2c1847371236c22a56.zip |
tdb_traverse/tdb_traverse_read: check returns for negative, not -1.
TDB2 returns a negative error number on failure. This is compatible
if we always check for < 0 instead of == -1.
Also, there's no tdb_traverse_read in TDB2: we don't try to make
traverse reliable any more, so there are no write locks anyway.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source3/rpc_server/srvsvc')
-rw-r--r-- | source3/rpc_server/srvsvc/srv_srvsvc_nt.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/rpc_server/srvsvc/srv_srvsvc_nt.c b/source3/rpc_server/srvsvc/srv_srvsvc_nt.c index 64a7264ece..2aed300feb 100644 --- a/source3/rpc_server/srvsvc/srv_srvsvc_nt.c +++ b/source3/rpc_server/srvsvc/srv_srvsvc_nt.c @@ -136,7 +136,7 @@ static WERROR net_enum_pipes(TALLOC_CTX *ctx, fenum.username = username; fenum.ctr3 = *ctr3; - if (connections_traverse(pipe_enum_fn, &fenum) == -1) { + if (connections_traverse(pipe_enum_fn, &fenum) < 0) { DEBUG(0,("net_enum_pipes: traverse of connections.tdb " "failed\n")); return WERR_NOMEM; |