Alexandre Julliard : kernel32: Fix a FAT format sanity check for floppies.

Alexandre Julliard julliard at winehq.org
Thu Dec 2 16:30:52 CST 2010


Module: wine
Branch: stable
Commit: 277061efb96784e935d02911deb620426dae1bda
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=277061efb96784e935d02911deb620426dae1bda

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Mon Oct 25 12:40:54 2010 +0200

kernel32: Fix a FAT format sanity check for floppies.
(cherry picked from commit 1379269587e6f158a22e2bc784861a881e23f3d1)

---

 dlls/kernel32/volume.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/kernel32/volume.c b/dlls/kernel32/volume.c
index 002a7e6..9810260 100644
--- a/dlls/kernel32/volume.c
+++ b/dlls/kernel32/volume.c
@@ -336,7 +336,7 @@ static enum fs_type VOLUME_ReadFATSuperblock( HANDLE handle, BYTE *buff )
         reasonable = num_boot_sectors < total_sectors &&
                      num_fats < 16 &&
                      bytes_per_sector >= 512 && bytes_per_sector % 512 == 0 &&
-                     sectors_per_cluster > 1;
+                     sectors_per_cluster >= 1;
         if (!reasonable) return FS_UNKNOWN;
         sectors =  total_sectors - num_boot_sectors - num_fats * sect_per_fat -
             (num_root_dir_ents * 32 + bytes_per_sector - 1) / bytes_per_sector;




More information about the wine-cvs mailing list