diff options
author | Samba Release Account <samba-bugs@samba.org> | 1997-02-28 20:39:36 +0000 |
---|---|---|
committer | Samba Release Account <samba-bugs@samba.org> | 1997-02-28 20:39:36 +0000 |
commit | da0a56a278232bad50ea0dd05de3b06299d66234 (patch) | |
tree | 38f0974d6caf71c698ae9d2ab2fcdace6ac8e28e /source3/smbd/trans2.c | |
parent | 0fb433564c6c8959ccd788f19012348634416ec1 (diff) | |
download | samba-da0a56a278232bad50ea0dd05de3b06299d66234.tar.gz samba-da0a56a278232bad50ea0dd05de3b06299d66234.tar.bz2 samba-da0a56a278232bad50ea0dd05de3b06299d66234.zip |
Split maxxmit parameter into two : max_send (auto configured by the
connecting client, as per CIFS4) and max_recv, which can be configured
as the old maxxmit was. Fixes problems with NT directory listings when
maxxmit is set very small.
jra@cygnus.com
(This used to be commit c2d5d1040a933987a0c39545bb5bf8e2fc400a87)
Diffstat (limited to 'source3/smbd/trans2.c')
-rw-r--r-- | source3/smbd/trans2.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index ab2fe88536..2c0d5903e6 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -40,13 +40,13 @@ extern int Client; static int send_trans2_replies(char *outbuf, int bufsize, char *params, int paramsize, char *pdata, int datasize) { - /* As we are using a protocol > LANMAN1 then the maxxmit + /* As we are using a protocol > LANMAN1 then the max_send variable must have been set in the sessetupX call. This takes precedence over the max_xmit field in the global struct. These different max_xmit variables should be merged as this is now too confusing */ - extern int maxxmit; + extern int max_send; int data_to_send = datasize; int params_to_send = paramsize; int useable_space; @@ -71,9 +71,9 @@ static int send_trans2_replies(char *outbuf, int bufsize, char *params, /* The alignment_offset is to align the param and data bytes on an even byte boundary. NT 4.0 Beta needs this to work correctly. */ useable_space = bufsize - ((smb_buf(outbuf)+alignment_offset) - outbuf); - /* useable_space can never be more than maxxmit minus the + /* useable_space can never be more than max_send minus the alignment offset. */ - useable_space = MIN(useable_space, maxxmit - alignment_offset); + useable_space = MIN(useable_space, max_send - alignment_offset); while( params_to_send || data_to_send) { |