svn commit: samba r3352 - in branches/SAMBA_4_0/source/libcli: .
tridge at samba.org
tridge at samba.org
Fri Oct 29 05:31:36 GMT 2004
Author: tridge
Date: 2004-10-29 05:31:35 +0000 (Fri, 29 Oct 2004)
New Revision: 3352
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=3352
Log:
make smbcli_read() and smbcli_write() work with very small negotiated SMB buffer sizes
Modified:
branches/SAMBA_4_0/source/libcli/clireadwrite.c
Changeset:
Modified: branches/SAMBA_4_0/source/libcli/clireadwrite.c
===================================================================
--- branches/SAMBA_4_0/source/libcli/clireadwrite.c 2004-10-29 04:43:28 UTC (rev 3351)
+++ branches/SAMBA_4_0/source/libcli/clireadwrite.c 2004-10-29 05:31:35 UTC (rev 3352)
@@ -42,8 +42,7 @@
* Set readsize to the maximum size we can handle in one readX,
* rounded down to a multiple of 1024.
*/
- readsize = (tree->session->transport->negotiate.max_xmit -
- (MIN_SMB_SIZE+32)) & ~1023;
+ readsize = (tree->session->transport->negotiate.max_xmit - (MIN_SMB_SIZE+32));
if (readsize > 0xFFFF) readsize = 0xFFFF;
while (total < size) {
@@ -87,7 +86,7 @@
const uint8_t *buf, off_t offset, size_t size)
{
union smb_write parms;
- int block = (tree->session->transport->negotiate.max_xmit - (MIN_SMB_SIZE+32)) & ~1023;
+ int block = (tree->session->transport->negotiate.max_xmit - (MIN_SMB_SIZE+32));
ssize_t total = 0;
if (size == 0) {
More information about the samba-cvs
mailing list