mirror of
https://github.com/php/php-src.git
synced 2024-11-29 04:46:07 +08:00
In NetWare statfs f_bavail member is known as f_bfree
This commit is contained in:
parent
8d73dc7bfc
commit
f43386764f
@ -311,8 +311,12 @@ PHP_FUNCTION(disk_free_space)
|
||||
}
|
||||
#elif (defined(HAVE_SYS_STATFS_H) || defined(HAVE_SYS_MOUNT_H)) && defined(HAVE_STATFS)
|
||||
if (statfs(Z_STRVAL_PP(path), &buf)) RETURN_FALSE;
|
||||
#ifdef NETWARE
|
||||
bytesfree = (((double)buf.f_bsize) * ((double)buf.f_bfree));
|
||||
#else
|
||||
bytesfree = (((double)buf.f_bsize) * ((double)buf.f_bavail));
|
||||
#endif
|
||||
#endif
|
||||
#endif /* WINDOWS */
|
||||
|
||||
RETURN_DOUBLE(bytesfree);
|
||||
|
Loading…
Reference in New Issue
Block a user