how to calculate correctly the cluster size

Sylwia lubowiecka at go2.pl
Tue Apr 13 08:15:44 EDT 2004


Hi!

I need Your help...

I am trying to find a way to calculate the cluster size for a drive. I
looked at the GetDiskFreeSpaceEx function in Win32 and it turned out
that it didn't provide the information I was looking for.
Using the old GetDiskFreeSpace function I could just multiply the
Bytes per
Sector by the Sector per Cluster and get the cluster size.  I heard
that the old GetDiskFreeSpace function may report not proper values
for volume sizes that are greater than 2 gigabytes. The new version of
that function (GetDiskFreeSpaceEx) returns the final disk free size
without the ability to calculate the cluster size - and the old
version does not work correctly with FAT 32... what can I do? Is there
another function I can use?

Thank You in advance,

Farraige



More information about the Python-list mailing list