in reply to Real live code
There's nothing wrong with non-portable code, if you have no intention of ever porting it. But Win32::AdminMisc::GetDriveSpace() would be a better choice here. (Note: this is a reply to an old node, and is just for the benefit of anyone who runs across this thread and needs to do a similar thing).