----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/68398/#review207786 -----------------------------------------------------------
3rdparty/stout/include/stout/posix/fs.hpp Lines 49 (patched) <https://reviews.apache.org/r/68398/#comment291285> Nit: A space after the minus sign. Also the subexpression would result in an `unsigned long`, which is just "at least 32 bits" according to the C++ standard: https://en.cppreference.com/w/cpp/language/types#Properties It's probably fine but I was wondering if we should do the following instead: ``` (buf.f_blocks - buf.f_bfree) * static_cast<size_t>(buf.f_frsize) ``` 3rdparty/stout/include/stout/windows/fs.hpp Lines 55 (patched) <https://reviews.apache.org/r/68398/#comment291286> If the code in this chain is unix-only, should we just not introduce this function for now? 3rdparty/stout/tests/os_tests.cpp Lines 1154 (patched) <https://reviews.apache.org/r/68398/#comment291287> If we don't introduce the `used` function, we could guard the whole test with `#ifndef __WINDOWS__`. - Chun-Hung Hsiao On Aug. 16, 2018, 11:51 p.m., James Peach wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/68398/ > ----------------------------------------------------------- > > (Updated Aug. 16, 2018, 11:51 p.m.) > > > Review request for mesos, Chun-Hung Hsiao, Ilya Pronin, Jie Yu, Joseph Wu, > and Jiang Yan Xu. > > > Bugs: MESOS-5158 > https://issues.apache.org/jira/browse/MESOS-5158 > > > Repository: mesos > > > Description > ------- > > Added a `fs::used` API that returns the amount of used space on a > given filesystem. > > > Diffs > ----- > > 3rdparty/stout/include/stout/posix/fs.hpp > 269a4f50f1df8d68be9e11030f885cf2c254c9d8 > 3rdparty/stout/include/stout/windows/fs.hpp > cc9a56012bd17cf962c8bc6d59ae221fcf19ecba > 3rdparty/stout/tests/os_tests.cpp b80c34e8e84cab68de7c843c7eafefbd84c3328c > > > Diff: https://reviews.apache.org/r/68398/diff/1/ > > > Testing > ------- > > sudo make check (Fedora 28) > > > Thanks, > > James Peach > >
