----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/13387/#review24934 -----------------------------------------------------------
3rdparty/libprocess/3rdparty/stout/Makefile.am <https://reviews.apache.org/r/13387/#comment49084> Thanks for moving this out! Would be great to add read_tests.cpp while you're at it :) 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp <https://reviews.apache.org/r/13387/#comment49085> s/text// s/content/contents/ 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp <https://reviews.apache.org/r/13387/#comment49086> s/Error/ErrnoError/ 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp <https://reviews.apache.org/r/13387/#comment49092> std::string(line, read), otherwise if the input has null bytes you'll miss them and anything after them in the input. 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp <https://reviews.apache.org/r/13387/#comment49094> newline? 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp <https://reviews.apache.org/r/13387/#comment49093> kill '&& errno != 0', since the documentation states that errno will be set if an error occurs 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp <https://reviews.apache.org/r/13387/#comment49095> Isn't the delimiter included in the buffer? Does this produce additional newlines? If so, then let's just s/lines/result/ and use result.append(line, read) to build up the result. On this note, can you add some tests? - Ben Mahler On Aug. 9, 2013, 3:13 a.m., Jiang Yan Xu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/13387/ > ----------------------------------------------------------- > > (Updated Aug. 9, 2013, 3:13 a.m.) > > > Review request for mesos, Benjamin Hindman, Ben Mahler, and Vinod Kone. > > > Bugs: MESOS-534 > https://issues.apache.org/jira/browse/MESOS-534 > > > Repository: mesos-git > > > Description > ------- > > - Removed os::read(int fd) because it's not used elsewhere. > - Separated os::read()s into os/read.hpp. > > > Diffs > ----- > > 3rdparty/libprocess/3rdparty/stout/Makefile.am > 770378d11d30e1e222e418c1839affd9d4ffe8d3 > 3rdparty/libprocess/3rdparty/stout/include/stout/os.hpp > 448739e313bf5127e7e5469dd4090445dc5c5405 > 3rdparty/libprocess/3rdparty/stout/include/stout/os/read.hpp PRE-CREATION > > Diff: https://reviews.apache.org/r/13387/diff/ > > > Testing > ------- > > make check > > > Thanks, > > Jiang Yan Xu > >
