| Summary: | Incorrect free space reported in status bar when accessing an NFS share | ||
|---|---|---|---|
| Product: | [Unmaintained] kdelibs | Reporter: | timothy.wilson87 |
| Component: | general | Assignee: | David Faure <faure> |
| Status: | RESOLVED WORKSFORME | ||
| Severity: | normal | CC: | faure, jjm, peter.penz19, timothy.wilson87 |
| Priority: | NOR | ||
| Version First Reported In: | SVN | ||
| Target Milestone: | --- | ||
| Platform: | FreeBSD Ports | ||
| OS: | FreeBSD | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
timothy.wilson87
2010-01-22 04:05:26 UTC
Thanks Timothy for the report! One information would be very useful for me to be able to fix this bug (as I've no NFS here): Could you please go to you mount point, open the context menu and select "Properties"? At the bottom there is a bar "device usage" - does it also show the same problem as the space information of the statusbar? Thanks in advance! Hello Peter, Yes, the "Device usage" under "Properties" is also wrong. It too shows the same incorrect size that is being reported in the status bar. Something I didn't mention is that "df -h" shows the correct usage on the NFS client. Is there any other information I can provide? Thanks! Timothy. @David: Dolphin and KPropertiesDialog use KDiskFreeSpaceInfo::freeSpaceInfo() to get the free disk space. Hmm I can't reproduce this, with a linux NFS mount. df says 808G free and the properties dialog says 807.9 GiB free, seems pretty correct.
The relevant code from KDiskSpaceFreeInfo is:
struct statvfs statvfs_buf;
// Prefer mountPoint if available, so that it even works with non-existing files.
const QString pathArg = info.d->mountPoint.isEmpty() ? path : info.d->mountPoint;
if (!statvfs(QFile::encodeName(pathArg).constData(), &statvfs_buf)) {
const quint64 blksize = quint64(statvfs_buf.f_frsize); // cast to avoid overflow
info.d->available = statvfs_buf.f_bavail * blksize;
info.d->size = statvfs_buf.f_blocks * blksize;
info.d->valid = true;
}
Actually the "use frsize" fix is from July, and the "overflow" fix is from February, and both could be the cause for your bug.
I see a huge chance that this is fixed already, can you update to a more recent KDE version (4.5.x) and test again?
Reported for KDE4. Please confirm if the problem is still seen with current version. Dear Bug Submitter, This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging If you have already provided the requested information, please mark the bug as REPORTED so that the KDE team knows that the bug is ready to be confirmed. Thank you for helping us make KDE software even better for everyone! This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information. For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging Thank you for helping us make KDE software even better for everyone! |