aboutsummaryrefslogtreecommitdiffstats
path: root/fs/cifs/readdir.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/cifs/readdir.c')
-rw-r--r--fs/cifs/readdir.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/fs/cifs/readdir.c b/fs/cifs/readdir.c
index b5b0a2a41bef..ed18c3965f7b 100644
--- a/fs/cifs/readdir.c
+++ b/fs/cifs/readdir.c
@@ -896,6 +896,10 @@ static int cifs_filldir(char *pfindEntry, struct file *file,
896 tmp_inode->i_ino,obj_type); 896 tmp_inode->i_ino,obj_type);
897 if(rc) { 897 if(rc) {
898 cFYI(1,("filldir rc = %d",rc)); 898 cFYI(1,("filldir rc = %d",rc));
899 /* we can not return filldir errors to the caller
900 since they are "normal" when the stat blocksize
901 is too small - we return remapped error instead */
902 rc = -EOVERFLOW;
899 } 903 }
900 904
901 dput(tmp_dentry); 905 dput(tmp_dentry);
@@ -1074,6 +1078,11 @@ int cifs_readdir(struct file *file, void *direntry, filldir_t filldir)
1074 we want to check for that here? */ 1078 we want to check for that here? */
1075 rc = cifs_filldir(current_entry, file, 1079 rc = cifs_filldir(current_entry, file,
1076 filldir, direntry, tmp_buf, max_len); 1080 filldir, direntry, tmp_buf, max_len);
1081 if(rc == -EOVERFLOW) {
1082 rc = 0;
1083 break;
1084 }
1085
1077 file->f_pos++; 1086 file->f_pos++;
1078 if(file->f_pos == 1087 if(file->f_pos ==
1079 cifsFile->srch_inf.index_of_last_entry) { 1088 cifsFile->srch_inf.index_of_last_entry) {