Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 975bd46c authored by Yi Kong's avatar Yi Kong Committed by android-build-merger
Browse files

Fix android-cloexec-pipe clang-tidy warning

am: 1fa946a2

Change-Id: I5602656a601581154361bb6452dc0ee018d27029
parents 2b952530 1fa946a2
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -15,6 +15,7 @@
 */

#include <dirent.h>
#include <fcntl.h>

#include <set>
#include <string>
@@ -69,7 +70,7 @@ TEST(FileUtilsTests, FindFilesFindApkFilesRecursive) {

TEST(FileUtilsTests, ReadFile) {
  int pipefd[2];
  ASSERT_EQ(pipe(pipefd), 0);
  ASSERT_EQ(pipe2(pipefd, O_CLOEXEC), 0);

  ASSERT_EQ(write(pipefd[1], "foobar", 6), 6);
  close(pipefd[1]);