From 8a8a7da5186596ee86b0b188156bca7d5e664784 Mon Sep 17 00:00:00 2001 From: Luke Leighton Date: Sat, 4 Dec 1999 00:49:13 +0000 Subject: argh! you wouldn't believe what i had to do: use the mid (multiplex id) to redirect multiple socket-based connnections onto a single client state. argh! (This used to be commit 06390e792cd8aa57a91c3a3d1d267fd1bcdc17a1) --- source3/libsmb/clientgen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/libsmb/clientgen.c') diff --git a/source3/libsmb/clientgen.c b/source3/libsmb/clientgen.c index 985d1c496d..fea105887f 100644 --- a/source3/libsmb/clientgen.c +++ b/source3/libsmb/clientgen.c @@ -1597,7 +1597,7 @@ size_t cli_read(struct cli_state *cli, int fnum, char *buf, off_t offset, size_t int total = -1; int issued=0; int received=0; - int mpx = MAX(cli->max_mux-1, 1); + int mpx = MIN(MAX(cli->max_mux-1, 1), MAX_MAX_MUX_LIMIT); int block = (cli->max_xmit - (smb_size+32)) & ~1023; int mid; int blocks = (size + (block-1)) / block; -- cgit