commit | 1666bafa7074a6fa3a745229931a8292da1f41bd | [log] [tgz] |
---|---|---|
author | Mathieu Chartier <mathieuc@google.com> | Fri Nov 02 08:05:31 2018 -0700 |
committer | Mathieu Chartier <mathieuc@google.com> | Fri Nov 02 08:24:38 2018 -0700 |
tree | 66574b7a4bd1a39724d773d86a9820a2a7c5c6a2 | |
parent | 6d7c8fcc92c4914dc01de4f82ac3b39abebff264 [diff] |
libbase: add Fdopendir that takes a unique_fd. Using fdopendir with unique_fd correctly is more annoying than it should be, because fdopendir doesn't close the file descriptor received upon failure. Add an android::base::Fdopendir that does that handles the failure case. Bug: 118818285 Test: treehugger Change-Id: I5dbbe0eb82242bc7716f84735ffc7644febcfd65