summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2003-03-20 00:52:37 +0000
committerJeremy Allison <jra@samba.org>2003-03-20 00:52:37 +0000
commit3be18a1fba5b008e55a4497470165de62aa15054 (patch)
tree4adf72ee173185d4a392154b8a01b3d97c161786 /source3/lib
parent4377376832b9ce40c7a7b99e04c23c25d96915ca (diff)
downloadsamba-3be18a1fba5b008e55a4497470165de62aa15054.tar.gz
samba-3be18a1fba5b008e55a4497470165de62aa15054.tar.bz2
samba-3be18a1fba5b008e55a4497470165de62aa15054.zip
lib/messages.c: Check return from chainlock before modifying message queue.
Apply the job returned limit across all requests for job queues. Jeremy. (This used to be commit bf795b684e608f82db822e0759e7b69afd451b65)
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/messages.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source3/lib/messages.c b/source3/lib/messages.c
index 5ff0e45c61..c078472880 100644
--- a/source3/lib/messages.c
+++ b/source3/lib/messages.c
@@ -315,7 +315,9 @@ static BOOL retrieve_all_messages(char **msgs_buf, size_t *total_len)
kbuf = message_key_pid(sys_getpid());
- tdb_chainlock(tdb, kbuf);
+ if (tdb_chainlock(tdb, kbuf) == -1)
+ return False;
+
dbuf = tdb_fetch(tdb, kbuf);
/*
* Replace with an empty record to keep the allocated