summaryrefslogtreecommitdiff
path: root/package/sash/src/df.c
diff options
context:
space:
mode:
authormirabilos <tg@mirbsd.org>2017-11-18 12:37:08 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2017-11-19 09:09:27 +0100
commit69229e524cde4412eb111180f15e073cc00366d9 (patch)
treebbe1a9e2f1157ca23b233fcf2d73a8c1f229d4a6 /package/sash/src/df.c
parentd68e2217231db1a738374dbff846a5612be621a0 (diff)
clean up sash
Signed-off-by: mirabilos <tg@mirbsd.org>
Diffstat (limited to 'package/sash/src/df.c')
-rw-r--r--package/sash/src/df.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/package/sash/src/df.c b/package/sash/src/df.c
index 99ac2217e..8f2c05533 100644
--- a/package/sash/src/df.c
+++ b/package/sash/src/df.c
@@ -41,15 +41,14 @@ do_df(int argc, char * argv[])
name = "/";
else
name = argv[1];
-
+
if (statfs(name, &stbuf) == -1) {
printf("Unable to get disk space of %s: %s\n", name, strerror(errno));
return;
}
-
+
printf("Total Kbytes: %ld\n", (stbuf.f_bsize / 256) * (stbuf.f_blocks / 4));
printf("Free Kbytes: %ld\n", (stbuf.f_bsize / 256) * (stbuf.f_bfree / 4));
printf("Total nodes: %ld\n", stbuf.f_files);
printf("Free nodes: %ld\n", stbuf.f_ffree);
}
-