Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2c5885e

Browse filesBrowse files
authored
Fix info.usedBytes calculation giving weird result (esp8266#8445)
1 parent 4c07113 commit 2c5885e
Copy full SHA for 2c5885e

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed

‎libraries/SDFS/src/SDFS.h

Copy file name to clipboardExpand all lines: libraries/SDFS/src/SDFS.h
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class SDFSImpl : public FSImpl
101101
info.pageSize = 0; // TODO ?
102102
info.maxPathLength = 255; // TODO ?
103103
info.totalBytes =_fs.vol()->clusterCount() * info.blockSize;
104-
info.usedBytes = info.totalBytes - (_fs.vol()->freeClusterCount() * _fs.vol()->bytesPerCluster());
104+
info.usedBytes = (_fs.vol()->clusterCount() - _fs.vol()->freeClusterCount()) * info.blockSize;
105105
return true;
106106
}
107107

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.