]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
filestore: compare dentry->d_type against d_type constant
authorJosh Durgin <josh.durgin@dreamhost.com>
Fri, 3 Jun 2011 01:17:29 +0000 (18:17 -0700)
committerJosh Durgin <josh.durgin@dreamhost.com>
Fri, 3 Jun 2011 01:21:24 +0000 (18:21 -0700)
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
src/os/FileStore.cc

index 0c64bcf21df343eec3e610d92100177b994b5279..3979dda3c81d08b2c4315c24e2ad77edc310f01d 100644 (file)
@@ -3665,7 +3665,7 @@ int FileStore::list_collections(vector<coll_t>& ls)
       if (!S_ISDIR(sb.st_mode)) {
        continue;
       }
-    } else if (!S_ISDIR(de->d_type << 12)) {
+    } else if (de->d_type != DT_DIR) {
       continue;
     }
     if (de->d_name[0] == '.' &&