commit | 1197f7234dcad770dedc06ede58b37202ae2b780 | [log] [tgz] |
---|---|---|
author | Josh Gao <jmgao@google.com> | Fri Aug 09 14:33:34 2019 -0700 |
committer | Josh Gao <jmgao@google.com> | Fri Aug 09 14:33:34 2019 -0700 |
tree | 075c283e11c19b75f64635e10410b8a6b3aee57f | |
parent | 6f65b7f0dda9bbd70ca156487ac195821b4ff94b [diff] [blame] |
installd_dexopt_test: fix close of owned file descriptor. fdopen takes ownership of the file descriptor passed in, so the file descriptor must not be closed directly. Bug: http://b/139092341 Test: treehugger Change-Id: I1132bfe7b1b8bcea80fd264ae7832603cdec69cd
diff --git a/cmds/installd/tests/installd_dexopt_test.cpp b/cmds/installd/tests/installd_dexopt_test.cpp index 73780ec..0212bc5 100644 --- a/cmds/installd/tests/installd_dexopt_test.cpp +++ b/cmds/installd/tests/installd_dexopt_test.cpp
@@ -275,7 +275,7 @@ writer.StartEntry("primary.prof", ZipWriter::kCompress); writer.FinishEntry(); writer.Finish(); - close(fd); + fclose(file); } // Create the app user data.