> On Nov. 11, 2016, 1:06 a.m., Benjamin Mahler wrote: > > 3rdparty/libprocess/src/poll_socket.cpp, lines 109-115 > > <https://reviews.apache.org/r/53457/diff/1/?file=1554060#file1554060line109> > > > > This introduces a leakable path for the 's' file descriptor: if create > > fails, 's' is not closed. > > It turns out that create cannot fail currently, but of course we don't > > want to rely on this :) > > > > Seems we could either continue to have accept return a Socket::Impl to > > avoid the caller here having to think about closing, or we can perform an > > os::close if create fails.
This was just a copy-paste bug, thanks for catching! - Benjamin ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/53457/#review155680 ----------------------------------------------------------- On Nov. 4, 2016, 6:40 a.m., Benjamin Hindman wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/53457/ > ----------------------------------------------------------- > > (Updated Nov. 4, 2016, 6:40 a.m.) > > > Review request for mesos, Benjamin Mahler and Jie Yu. > > > Repository: mesos > > > Description > ------- > > Updated Socket::Impl::accept to return std::shared_ptr<Impl>. > > > Diffs > ----- > > 3rdparty/libprocess/include/process/socket.hpp > f798af7879546d71e8ef4a295c9cf489a70cb61f > 3rdparty/libprocess/src/poll_socket.hpp > d04f3f2d1bcf70464ac659b29f96574bbd233414 > 3rdparty/libprocess/src/poll_socket.cpp > f0ee1490e6fccb038f64a27b2c71458ad5b5e5a1 > > Diff: https://reviews.apache.org/r/53457/diff/ > > > Testing > ------- > > make check > > > Thanks, > > Benjamin Hindman > >
