mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
fixed disk space estimation for large file systems
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2992 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
7db10d1f6f
commit
1122e9fa56
@ -82,9 +82,9 @@ bool RsDiscSpace::crossSystemDiskStats(const char *file, uint32_t& free_blocks,
|
|||||||
free_blocks = dwFreeClusters ;
|
free_blocks = dwFreeClusters ;
|
||||||
block_size = dwSectorPerCluster * dwBytesPerSector ;
|
block_size = dwSectorPerCluster * dwBytesPerSector ;
|
||||||
#else
|
#else
|
||||||
struct statvfs buf;
|
struct statvfs64 buf;
|
||||||
|
|
||||||
if (0 != statvfs (file, &buf))
|
if (0 != statvfs64 (file, &buf))
|
||||||
{
|
{
|
||||||
std::cerr << "Size estimate failed for file " << file << std::endl ;
|
std::cerr << "Size estimate failed for file " << file << std::endl ;
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user