summaryrefslogtreecommitdiff
path: root/compiler/dex/arena_allocator.cc
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/dex/arena_allocator.cc')
-rw-r--r--compiler/dex/arena_allocator.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/dex/arena_allocator.cc b/compiler/dex/arena_allocator.cc
index 2da806437c..95e44b3e0d 100644
--- a/compiler/dex/arena_allocator.cc
+++ b/compiler/dex/arena_allocator.cc
@@ -50,7 +50,9 @@ Arena::Arena(size_t size)
map_(nullptr),
next_(nullptr) {
if (kUseMemMap) {
- map_ = MemMap::MapAnonymous("dalvik-arena", NULL, size, PROT_READ | PROT_WRITE);
+ std::string error_msg;
+ map_ = MemMap::MapAnonymous("dalvik-arena", NULL, size, PROT_READ | PROT_WRITE, &error_msg);
+ CHECK(map_ != nullptr) << error_msg;
memory_ = map_->Begin();
size_ = map_->Size();
} else {