From 2c6472ee5a27284c85c00dc2800df2c595c4c924 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-Pierre=20Andr=C3=A9?= Date: Sat, 7 Mar 2020 10:43:00 +0100 Subject: [PATCH] Accepted alternative recording of cluster size Since Windows 10, the cluster size may be greater than 128 sectors, and it has to be recorded as a power of 2 in the boot sector. Hence there are two possible ways of cluster size. Accept both ways leading to valid values. --- libntfs-3g/bootsect.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libntfs-3g/bootsect.c b/libntfs-3g/bootsect.c index b0ac4d7a..e9eb0b15 100644 --- a/libntfs-3g/bootsect.c +++ b/libntfs-3g/bootsect.c @@ -86,7 +86,7 @@ BOOL ntfs_boot_sector_is_ntfs(NTFS_BOOT_SECTOR *b) break; default: if ((b->bpb.sectors_per_cluster < 240) - || (b->bpb.sectors_per_cluster > 249)) { + || (b->bpb.sectors_per_cluster > 253)) { if (b->bpb.sectors_per_cluster > 128) ntfs_log_error("Unexpected sectors" " per cluster value (code 0x%x)\n",