From 4fd802c444eac0e4ef270d35e6675d7a8f1de57f Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 16 Apr 2002 13:10:54 +0000 Subject: fixed a problem with the smb_buf() macro on some compilers (This used to be commit 66d6d4810ab7b0a1bf2039c387938aad69e01569) --- source3/include/smb_macros.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source3/include/smb_macros.h b/source3/include/smb_macros.h index 27a5961651..a2351c705e 100644 --- a/source3/include/smb_macros.h +++ b/source3/include/smb_macros.h @@ -169,7 +169,7 @@ #define SMB_ROUNDUP_ALLOCATION(s) ((s) ? (SMB_ROUNDUP((SMB_OFF_T)((s)+1), ((SMB_OFF_T)SMB_ROUNDUP_ALLOCATION_SIZE))) : 0 ) /* Extra macros added by Ying Chen at IBM - speed increase by inlining. */ -#define smb_buf(buf) ((buf) + smb_size + CVAL(buf,smb_wct)*2) +#define smb_buf(buf) (((char *)(buf)) + smb_size + CVAL(buf,smb_wct)*2) #define smb_buflen(buf) (SVAL(buf,smb_vwv0 + (int)CVAL(buf, smb_wct)*2)) /* the remaining number of bytes in smb buffer 'buf' from pointer 'p'. */ -- cgit