wlschmidt / lcdmiscellany

Automatically exported from code.google.com/p/lcdmiscellany
1 stars 1 forks source link

Drive Space Error #4

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
It probably has something to do with the NTFS junction linking "My
Documents" across two drives.

What is the expected output? What do you see instead?
For Drive C it should report 160GB, but instead it shows 1.7TB for both
drives (only the second drive is this large)

What version of the product are you using? On what operating system?
XP Pro x32, LCD 0.4.5.0

Original issue reported on code.google.com by link68...@gmail.com on 31 Dec 2009 at 3:32

GoogleCodeExporter commented 8 years ago
Thanks for reporting this.  If you're right about the cause of the issue, not 
sure I
can fix it, unfortunately.  I just return the results of Microsoft's
GetDiskFreeSpaceEx() function.

Just to make sure it's not a script bug of some sort, rather than an issue with 
my
drive space function, add these two lines to the top of Init() in LCD Misc.c 
and then
see what is written to the log (May be written just above the list of network
devices, or at the bottom, not sure):

WriteLogLn(FormatSize(GetDiskSpaceFree("C:\")) +s " / " +s
FormatSize(GetDiskSpaceTotal("C:\")));

WriteLogLn(FormatSize(GetDiskSpaceFree("D:\")) +s " / " +s
FormatSize(GetDiskSpaceTotal("D:\")));

If your drives aren't C and D, just change the letters as appropriate.

Original comment by mattme...@gmail.com on 31 Dec 2009 at 5:25

GoogleCodeExporter commented 8 years ago
It reports the correct values in the log, so it seems the function
works. Maybe the bug could be due to the fact that one is measured in
TB, while the other is measured in GB? Just a guess.

Original comment by link68...@gmail.com on 31 Dec 2009 at 5:50

GoogleCodeExporter commented 8 years ago
That's not it, either, as FormatSize() is the function I use in the script as 
well. 
Probably something to do with the drive detection script, though if it reports 
the
correct drive letters...  Really no idea what's going on.

Original comment by mattme...@gmail.com on 31 Dec 2009 at 5:54