summaryrefslogtreecommitdiff
path: root/runtime/vdex_file_test.cc
diff options
context:
space:
mode:
author Jiakai Zhang <jiakaiz@google.com> 2025-02-05 18:23:42 +0000
committer Treehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com> 2025-02-11 11:24:55 -0800
commit9dd0dc2b8997caa4abce1923177ff3951a237883 (patch)
tree81be25f389cd659b2d2a0f5cf90f44cf2ea098c0 /runtime/vdex_file_test.cc
parentac94fdd1de99bd059535f5ec562996eddcc227b4 (diff)
Remove more dead code for ELF file.
`writable` is always false. `program_header_only` is always true except for in some tests. The code that obtains information through ElfFile with `program_header_only=true` in tests are replaced by code that uses libelf. Bug: 377474232 Bug: 6527146 Test: art/test.py --host -g Change-Id: Icc9b4dbae612a90f54b50e090e191fad0a19f709
Diffstat (limited to 'runtime/vdex_file_test.cc')
-rw-r--r--runtime/vdex_file_test.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/runtime/vdex_file_test.cc b/runtime/vdex_file_test.cc
index 4c359e38c6..fb0c03aa6a 100644
--- a/runtime/vdex_file_test.cc
+++ b/runtime/vdex_file_test.cc
@@ -33,13 +33,11 @@ TEST_F(VdexFileTest, OpenEmptyVdex) {
std::unique_ptr<VdexFile> vdex = VdexFile::Open(tmp.GetFd(),
0,
tmp.GetFilename(),
- /*writable=*/false,
/*low_4gb=*/false,
&error_msg);
EXPECT_TRUE(vdex == nullptr);
- vdex = VdexFile::Open(
- tmp.GetFilename(), /*writable=*/false, /*low_4gb=*/false, &error_msg);
+ vdex = VdexFile::Open(tmp.GetFilename(), /*low_4gb=*/false, &error_msg);
EXPECT_TRUE(vdex == nullptr);
}