From 3e84be001ad613d491928a9dc6af52afa8aecc9e Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Wed, 14 Dec 2005 01:34:25 +0000 Subject: [PATCH] add dir_stat.disk_usage --- src/sigar_fileinfo.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/sigar_fileinfo.c b/src/sigar_fileinfo.c index c3a43582..d2f9a2a2 100644 --- a/src/sigar_fileinfo.c +++ b/src/sigar_fileinfo.c @@ -409,6 +409,10 @@ SIGAR_DECLARE(int) sigar_dir_stat_get(sigar_t *sigar, continue; } + dirstats->disk_usage += + (data.nFileSizeHigh * (MAXDWORD+1)) + + data.nFileSizeLow; + /* e.g. "C:\sigar\lib" */ strncpy(ptr, data.cFileName, max); ptr[max] = '\0';