summaryrefslogtreecommitdiff
path: root/libs/binder/ProcessState.cpp
diff options
context:
space:
mode:
author Steven Moreland <smoreland@google.com> 2021-02-18 19:10:15 +0000
committer Steven Moreland <smoreland@google.com> 2021-02-18 19:12:53 +0000
commit15b7029849a1c59ecb54961fa7417ee0611408a0 (patch)
treea77e42bbff918d0a45529effff82b4fe18b70608 /libs/binder/ProcessState.cpp
parente9441bcf32c04901807748bde85f16444464eb91 (diff)
Revert "libbinder: remove __ANDROID_APEX__ stability diff"
This reverts commit e9441bcf32c04901807748bde85f16444464eb91. Reason for revert: b/180559880#comment7 Bug: 179906909 Change-Id: I04472d3bbe97c9c42df74c10ce87c176fa7098dd
Diffstat (limited to 'libs/binder/ProcessState.cpp')
-rw-r--r--libs/binder/ProcessState.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/libs/binder/ProcessState.cpp b/libs/binder/ProcessState.cpp
index edadcd5c58..c38249ef7c 100644
--- a/libs/binder/ProcessState.cpp
+++ b/libs/binder/ProcessState.cpp
@@ -406,6 +406,12 @@ ProcessState::ProcessState(const char *driver)
, mThreadPoolSeq(1)
, mCallRestriction(CallRestriction::NONE)
{
+
+// TODO(b/166468760): enforce in build system
+#if defined(__ANDROID_APEX__)
+ LOG_ALWAYS_FATAL("Cannot use libbinder in APEX (only system.img libbinder) since it is not stable.");
+#endif
+
if (mDriverFD >= 0) {
// mmap the binder, providing a chunk of virtual address space to receive transactions.
mVMStart = mmap(nullptr, BINDER_VM_SIZE, PROT_READ, MAP_PRIVATE | MAP_NORESERVE, mDriverFD, 0);