summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosh Gao2018-05-23 11:44:53 -0500
committerJosh Gao2018-05-23 11:44:53 -0500
commitf139ba47a13de0637732af9fd70aab0e8c877e45 (patch)
treed61a5149997f33c85ee6625b71fea926007388ab
parent948b3e1068470cda390566452ccbaeb526a56e4e (diff)
downloadplatform-system-core-f139ba47a13de0637732af9fd70aab0e8c877e45.tar.gz
platform-system-core-f139ba47a13de0637732af9fd70aab0e8c877e45.tar.xz
platform-system-core-f139ba47a13de0637732af9fd70aab0e8c877e45.zip
Revert "adb: add support for O_CLOEXEC to unique_fd pipe wrapper."
This reverts commit 948b3e1068470cda390566452ccbaeb526a56e4e. Reason for revert: mac doesn't have pipe2 Change-Id: Id6a517bb500cbea602839f06452bc5e6d92289f1
-rw-r--r--adb/adb_unique_fd.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/adb/adb_unique_fd.h b/adb/adb_unique_fd.h
index 0dd86872d..9c02cbeec 100644
--- a/adb/adb_unique_fd.h
+++ b/adb/adb_unique_fd.h
@@ -28,9 +28,9 @@ struct AdbCloser {
28using unique_fd = android::base::unique_fd_impl<AdbCloser>; 28using unique_fd = android::base::unique_fd_impl<AdbCloser>;
29 29
30#if !defined(_WIN32) 30#if !defined(_WIN32)
31inline bool Pipe(unique_fd* read, unique_fd* write, int flags = 0) { 31inline bool Pipe(unique_fd* read, unique_fd* write) {
32 int pipefd[2]; 32 int pipefd[2];
33 if (pipe2(pipefd, flags) != 0) { 33 if (pipe(pipefd) != 0) {
34 return false; 34 return false;
35 } 35 }
36 read->reset(pipefd[0]); 36 read->reset(pipefd[0]);