|
From: | Aleksander Morgado |
Subject: | Re: [pdf-devel] pdf_fsys_disk_get_free_space() |
Date: | Sat, 15 Nov 2008 15:22:21 +0100 |
User-agent: | Thunderbird 2.0.0.17 (X11/20080925) |
As a side note, the Acrobat SDK provides two different data types and functions: typedef ASUns32 ASDiskSpace; ASFileSysGetStorageFreeSpace () typedef ASUns64 ASDiskSpace64; ASFileSysGetStorageFreeSpace64 () There are other functions with 64-bit versions. But I would avoid to use 64-bit specific alternatives if possible.
Uff, I don't like that.
Aleks, how are you implementing pdf_fsys_disk_get_free_space() for both POSIX and Windows?
I think we can go and use pdf_off_t as return value of the function. In Windows, you will get directly the number of free bytes as a ULARGE_INTEGER, using GetDiskFreeSpaceEx(). That number will be casted to a pdf_off_t to return it.
In POSIX I will leave the statfs() implementation, which computes the number of free bytes as (f_bfree*f_bsize).
[Prev in Thread] | Current Thread | [Next in Thread] |