----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/66038/#review200754 -----------------------------------------------------------
3rdparty/stout/include/stout/posix/fs.hpp Lines 62 (patched) <https://reviews.apache.org/r/66038/#comment281607> I was curious, and checked what this would do for an NTFS volume mounted via cifs on Linux. It reports 0/0, and this would then divide by zero. ``` > df -i Filesystem Inodes IUsed IFree IUse% Mounted on /dev/mapper/andschwa--ubuntu--vg-root 16482304 379480 16102824 3% / //andschwa-pc/public 0 0 0 - /mnt/public ``` Note the last line; total/used/free inodes are all zero. I could see this being the case for other non-POSIX filesystems (or network shares) that get mounted in Linux anyway. We should check if `f_files` is zero before dividing by it. - Andrew Schwartzmeyer On March 13, 2018, 7:08 a.m., fei long wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/66038/ > ----------------------------------------------------------- > > (Updated March 13, 2018, 7:08 a.m.) > > > Review request for mesos and Gilbert Song. > > > Bugs: MESOS-8665 > https://issues.apache.org/jira/browse/MESOS-8665 > > > Repository: mesos > > > Description > ------- > > Add usageWithInode to check both disk and inode usage. > > > Diffs > ----- > > 3rdparty/stout/include/stout/posix/fs.hpp > 269a4f50f1df8d68be9e11030f885cf2c254c9d8 > > > Diff: https://reviews.apache.org/r/66038/diff/2/ > > > Testing > ------- > > No new tests are added and all "make check" tests are passed. > > > Thanks, > > fei long > >
