OSDN Git Service

Fix clusters bitmap size.
[android-x86/external-exfat.git] / libexfat / node.c
index 3f58e9d..b544bd9 100644 (file)
@@ -469,8 +469,7 @@ static int readdir(struct exfat* ef, struct exfat_node* parent,
                                                ef->cmap.start_cluster);
                                return -EIO;
                        }
-                       ef->cmap.size = le32_to_cpu(ef->sb->cluster_count) -
-                               EXFAT_FIRST_DATA_CLUSTER;
+                       ef->cmap.size = le32_to_cpu(ef->sb->cluster_count);
                        if (le64_to_cpu(bitmap->size) < DIV_ROUND_UP(ef->cmap.size, 8))
                        {
                                exfat_error("invalid clusters bitmap size: %"PRIu64