TAKE 974905 - Initialise current offset in xfs_file_readdir correctly
Initialise current offset in xfs_file_readdir correctly
After reading the directory contents into the temporary buffer, we grab each dirent and pass it to filldir witht eh current offset of the dirent. The current offset was not being set for the first dirent in the temporary buffer, which coul dresult in bad offsets being set in the f_pos field result in looping and duplicate entries being returned from readdir.
Date: Thu Dec 20 16:32:49 AEDT 2007 Workarea: chook.melbourne.sgi.com:/build/dgc/isms/2.6.x-xfs Inspected by: [email protected]
The following file(s) were checked into:
longdrop.melbourne.sgi.com:/isms/linux/2.6.x-xfs-melb
Modid: xfs-linux-melb:xfs-kern:30282afs/xfs/linux-2.6/xfs_file.c - 1.161 - changed
http://oss.sgi.com/cgi-bin/cvsweb.cgi/xfs-linux/linux-2.6/xfs_file.c.diff?r1=text&tr1=1.161&r2=text&tr2=1.160&f=h
- Initialise the curr_offset correctly for the first dirent in each temp buffer during readdir.