summaryrefslogtreecommitdiff
path: root/source3/smbd/process.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2003-01-08 21:42:53 +0000
committerJeremy Allison <jra@samba.org>2003-01-08 21:42:53 +0000
commit38aee23f807dad93fb832d97deac57d528a2a175 (patch)
tree8ac8b73162e8722ef8078f6f2e77a56f8b6dcb5c /source3/smbd/process.c
parent82ecfb97475e8c7a524acc43f8232a8dcd3c120c (diff)
downloadsamba-38aee23f807dad93fb832d97deac57d528a2a175.tar.gz
samba-38aee23f807dad93fb832d97deac57d528a2a175.tar.bz2
samba-38aee23f807dad93fb832d97deac57d528a2a175.zip
Ensure we don't get an invalid number for total smbd's if the tdb update
fails. Jeremy. (This used to be commit e0482594724ebba801bbc39a90a73fafa54f8b9e)
Diffstat (limited to 'source3/smbd/process.c')
-rw-r--r--source3/smbd/process.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/source3/smbd/process.c b/source3/smbd/process.c
index 7421c16b40..03b1e007ba 100644
--- a/source3/smbd/process.c
+++ b/source3/smbd/process.c
@@ -809,17 +809,13 @@ static BOOL smbd_process_limit(void)
* subtracts one.
*/
- total_smbds = 1; /* In case we need to create the entry. */
-
if (!conn_tdb_ctx()) {
DEBUG(0,("smbd_process_limit: max smbd processes parameter set with status parameter not \
set. Ignoring max smbd restriction.\n"));
return False;
}
- if (tdb_change_int32_atomic(conn_tdb_ctx(), "INFO/total_smbds", &total_smbds, 1) == -1)
- return True;
-
+ total_smbds = increment_smbd_process_count();
return total_smbds > lp_max_smbd_processes();
}
else