Fix wimfs_getattr()
authorEric Biggers <ebiggers3@gmail.com>
Sat, 25 Aug 2012 19:52:41 +0000 (14:52 -0500)
committerEric Biggers <ebiggers3@gmail.com>
Sat, 25 Aug 2012 19:52:41 +0000 (14:52 -0500)
src/lookup_table.h
src/mount.c

index 4df2c6b..0490291 100644 (file)
@@ -10,7 +10,9 @@
 
 #define LOOKUP_FLAG_ADS_OK             0x00000001
 #define LOOKUP_FLAG_DIRECTORY_OK       0x00000002
-#define LOOKUP_FLAG_FOLLOW_SYMLINKS    0x00000004
+
+/* Not yet used */
+//#define LOOKUP_FLAG_FOLLOW_SYMLINKS  0x00000004
 
 
 /* A lookup table that is used to translate the hash codes of dentries into the
index ac4aeb3..58bbabe 100644 (file)
@@ -988,7 +988,9 @@ static int wimfs_getattr(const char *path, struct stat *stbuf)
        struct dentry *dentry;
        int ret;
 
-       ret = lookup_resource(w, path, get_lookup_flags(), &dentry, NULL, NULL);
+       ret = lookup_resource(w, path,
+                             get_lookup_flags() | LOOKUP_FLAG_DIRECTORY_OK,
+                             &dentry, NULL, NULL);
        if (ret != 0)
                return ret;
        return dentry_to_stbuf(dentry, stbuf);