aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/connect.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/connect.c')
-rw-r--r--fs/cifs/connect.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index 8d4657596301..ca20e813275d 100644
--- a/fs/cifs/connect.c
+++ b/fs/cifs/connect.c
@@ -318,9 +318,9 @@ static int coalesce_t2(struct smb_hdr *psecond, struct smb_hdr *pTargetSMB)
318 memcpy(data_area_of_target, data_area_of_buf2, total_in_buf2); 318 memcpy(data_area_of_target, data_area_of_buf2, total_in_buf2);
319 total_in_buf += total_in_buf2; 319 total_in_buf += total_in_buf2;
320 pSMBt->t2_rsp.DataCount = cpu_to_le16(total_in_buf); 320 pSMBt->t2_rsp.DataCount = cpu_to_le16(total_in_buf);
321 byte_count = le16_to_cpu(BCC_LE(pTargetSMB)); 321 byte_count = get_bcc_le(pTargetSMB);
322 byte_count += total_in_buf2; 322 byte_count += total_in_buf2;
323 BCC_LE(pTargetSMB) = cpu_to_le16(byte_count); 323 put_bcc_le(byte_count, pTargetSMB);
324 324
325 byte_count = pTargetSMB->smb_buf_length; 325 byte_count = pTargetSMB->smb_buf_length;
326 byte_count += total_in_buf2; 326 byte_count += total_in_buf2;
@@ -2937,8 +2937,8 @@ CIFSTCon(unsigned int xid, struct cifsSesInfo *ses,
2937 TCONX_RSP *pSMBr; 2937 TCONX_RSP *pSMBr;
2938 unsigned char *bcc_ptr; 2938 unsigned char *bcc_ptr;
2939 int rc = 0; 2939 int rc = 0;
2940 int length, bytes_left; 2940 int length;
2941 __u16 count; 2941 __u16 bytes_left, count;
2942 2942
2943 if (ses == NULL) 2943 if (ses == NULL)
2944 return -EIO; 2944 return -EIO;
@@ -3032,7 +3032,7 @@ CIFSTCon(unsigned int xid, struct cifsSesInfo *ses,
3032 tcon->need_reconnect = false; 3032 tcon->need_reconnect = false;
3033 tcon->tid = smb_buffer_response->Tid; 3033 tcon->tid = smb_buffer_response->Tid;
3034 bcc_ptr = pByteArea(smb_buffer_response); 3034 bcc_ptr = pByteArea(smb_buffer_response);
3035 bytes_left = BCC(smb_buffer_response); 3035 bytes_left = get_bcc(smb_buffer_response);
3036 length = strnlen(bcc_ptr, bytes_left - 2); 3036 length = strnlen(bcc_ptr, bytes_left - 2);
3037 if (smb_buffer->Flags2 & SMBFLG2_UNICODE) 3037 if (smb_buffer->Flags2 & SMBFLG2_UNICODE)
3038 is_unicode = true; 3038 is_unicode = true;