[linux-cifs-client] Re: Incorrect FIND_NEXT2 transmission causing

Steve French smfrench at austin.rr.com
Sun May 2 19:32:41 GMT 2004


> when a large number of files are present, it displays:
> dir000.txt to dir122.txt and nothing more

There may still be a problem with resume keys.  The two problems that I had run into in the past 
(and should be fixed) were:

1) the second or subsequent FindNext hit end of search, but the kernel (filldir) returned an 
error as cifs tried to add them to the directory listing during readdir, but the cifs client
at one point did not reopen the search and got an invalid handle on trying to resume the search
(using the old directory handle) from the last entry that the kernel took (the last successful
filldir) on the previous readdir.

2) the resume key was stored in ASCII but in some cases it was not converted back into Unicode
and the findNext returned an error trying to resume from an illegal file name.

I still do not like the search logic (cifs_readdir) code - it is just about my least favority part
of the code that I wrote - the NFS approach (grabbing a cache of NFS private pages to keep 
the search results in until the last readdir is issued and the search is closed may be a better
approach - but the memory utilization worries me)




More information about the linux-cifs-client mailing list