summaryrefslogtreecommitdiffstats
path: root/fs/efs/dir.c
diff options
context:
space:
mode:
authorAl Smith <Al.Smith@aeschi.ch.eu.org>1999-04-13 15:52:53 +0000
committerAl Smith <Al.Smith@aeschi.ch.eu.org>1999-04-13 15:52:53 +0000
commite9d2c29f0ad03e31b6264deb9605f25989791630 (patch)
tree312567059fbf6cd8fba968c9cda8ff617e219973 /fs/efs/dir.c
parentd6509c7221656060ff995b645dfc1eac582c7f31 (diff)
bug fixes: block/char devices fixed (NB: IRIX uses 32-bit wide dev_t,
linux only has 16-bit wide dev_t. this is apparently going to change in linux-2.3 but for now we can't handle devices with major or minor numbers > 255. handling of empty directory slots has been fixed.
Diffstat (limited to 'fs/efs/dir.c')
-rw-r--r--fs/efs/dir.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/fs/efs/dir.c b/fs/efs/dir.c
index 89dedbdb8..88e181690 100644
--- a/fs/efs/dir.c
+++ b/fs/efs/dir.c
@@ -46,8 +46,6 @@ struct inode_operations efs_dir_inode_operations = {
NULL /* smap */
};
-/* read the next entry for a given directory */
-
static int efs_readdir(struct file *filp, void *dirent, filldir_t filldir) {
struct inode *inode = filp->f_dentry->d_inode;
struct efs_inode_info *ini = INODE_INFO(inode);
@@ -94,6 +92,11 @@ static int efs_readdir(struct file *filp, void *dirent, filldir_t filldir) {
}
while(slot < dirblock->slots) {
+ if (dirblock->space[slot] == 0) {
+ slot++;
+ continue;
+ }
+
dirslot = (struct efs_dentry *) (((char *) bh->b_data) + EFS_SLOTAT(dirblock, slot));
inodenum = be32_to_cpu(dirslot->inode);