Merge "Init: error on oneway calls." am: ebae0d3ad9 am: 2a99b2011f
am: 998a8a965e
Change-Id: I32edf31026417898cd96833b4fd953e594a55a87
diff --git a/init/init.cpp b/init/init.cpp
index dc46a82..d360fdd 100644
--- a/init/init.cpp
+++ b/init/init.cpp
@@ -451,6 +451,8 @@
// Also, binder can't be used by recovery.
#ifndef RECOVERY
android::ProcessState::self()->setThreadPoolMaxThreadCount(0);
+ android::ProcessState::self()->setCallRestriction(
+ ProcessState::CallRestriction::ERROR_IF_NOT_ONEWAY);
#endif
return Success();
}