summaryrefslogtreecommitdiff
path: root/source3/include/smb_macros.h
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2007-11-02 12:21:34 -0700
committerJeremy Allison <jra@samba.org>2007-11-02 12:21:34 -0700
commit329365684bca99bf9020b6638a1357df65c1d938 (patch)
tree78d2ddfa0440fcaf14f4c9d4adbcf7c71572b968 /source3/include/smb_macros.h
parentf2a63dccabcd82ce2ae1cf0df5ce824c7ab63fc2 (diff)
downloadsamba-329365684bca99bf9020b6638a1357df65c1d938.tar.gz
samba-329365684bca99bf9020b6638a1357df65c1d938.tar.bz2
samba-329365684bca99bf9020b6638a1357df65c1d938.zip
Change the client library to write directly out of
the incoming buffer in the non-signed case. Speeds up writes by over 10% or so. Complete the server recvfile implementation. Jeremy. (This used to be commit 81ca5853b2475f123faab3b550f0a7b24ae3c208)
Diffstat (limited to 'source3/include/smb_macros.h')
-rw-r--r--source3/include/smb_macros.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/include/smb_macros.h b/source3/include/smb_macros.h
index 9af63451b0..0dfb596994 100644
--- a/source3/include/smb_macros.h
+++ b/source3/include/smb_macros.h
@@ -193,8 +193,8 @@
buf[2] = (len&0xFF00)>>8; buf[3] = len&0xFF; } while (0)
#define smb_len_large(buf) (PVAL(buf,3)|(PVAL(buf,2)<<8)|(PVAL(buf,1)<<16))
-#define _smb_setlen_large(buf,len) do { buf[0] = 0; buf[1] = (len&0xFF0000)>>16; \
- buf[2] = (len&0xFF00)>>8; buf[3] = len&0xFF; } while (0)
+#define _smb_setlen_large(buf,len) do { buf[0] = 0; buf[1] = ((len)&0xFF0000)>>16; \
+ buf[2] = ((len)&0xFF00)>>8; buf[3] = (len)&0xFF; } while (0)
/*******************************************************************
find the difference in milliseconds between two struct timeval