aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/cifs/cifssmb.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c
index 3c628bf667a5..0db0b313d715 100644
--- a/fs/cifs/cifssmb.c
+++ b/fs/cifs/cifssmb.c
@@ -2602,6 +2602,9 @@ int CIFSFindNext(const int xid, struct cifsTconInfo *tcon,
2602 if(name_len < PATH_MAX) { 2602 if(name_len < PATH_MAX) {
2603 memcpy(pSMB->ResumeFileName, psrch_inf->presume_name, name_len); 2603 memcpy(pSMB->ResumeFileName, psrch_inf->presume_name, name_len);
2604 byte_count += name_len; 2604 byte_count += name_len;
2605 /* 14 byte parm len above enough for 2 byte null terminator */
2606 pSMB->ResumeFileName[name_len] = 0;
2607 pSMB->ResumeFileName[name_len+1] = 0;
2605 } else { 2608 } else {
2606 rc = -EINVAL; 2609 rc = -EINVAL;
2607 goto FNext2_err_exit; 2610 goto FNext2_err_exit;