Reduce reserved size for DlExtTest.ReservedRecursiveTooSmall test

When built with clang-r353983, the ReservedRecursiveTooSmall test fail
due to the reserved memory is now large enough for android_dlopen_ext.
Reduce the reserved memory size to agree with ReservedTooSmall test.

Test: bionic-unit-tests
Bug: 126457671
Change-Id: I3e311a3f35b0de5d028fa1b9b3681d5ec32faee8
This commit is contained in:
Yi Kong 2019-03-14 16:25:45 -07:00
parent 10935e063d
commit 1e7a150339
1 changed files with 2 additions and 2 deletions

View File

@ -372,12 +372,12 @@ TEST_F(DlExtTest, ReservedRecursive) {
}
TEST_F(DlExtTest, ReservedRecursiveTooSmall) {
void* start = mmap(nullptr, kLibSize/2, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
void* start = mmap(nullptr, PAGE_SIZE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
ASSERT_TRUE(start != MAP_FAILED);
android_dlextinfo extinfo;
extinfo.flags = ANDROID_DLEXT_RESERVED_ADDRESS | ANDROID_DLEXT_RESERVED_ADDRESS_RECURSIVE;
extinfo.reserved_addr = start;
extinfo.reserved_size = kLibSize/2;
extinfo.reserved_size = PAGE_SIZE;
handle_ = android_dlopen_ext(kLibNameRecursive, RTLD_NOW, &extinfo);
EXPECT_EQ(nullptr, handle_);
}