diff options
author | 2020-09-18 01:04:15 +0000 | |
---|---|---|
committer | 2020-09-18 01:09:35 +0000 | |
commit | 9f50ea66b4cd4ddf436fea574f768a7fab7963ea (patch) | |
tree | 6c8055488eaca1bd3543f2d3a5a9a7ec6fcff942 /libs/binder/IPCThreadState.cpp | |
parent | 6ba4920c3ac53336b7a6c5f25abeb50bbd9d0f93 (diff) |
libbinder: ignore CallRestriction for magic 0 cmd
There is a special transaction required to make sure that the context
manager is setup before we get a reference to it. Since this is required
to use binder, it would prevent use of CallRestriction outside of
servicemanager.
Fixes: 167302413
Test: binderLibTest
Change-Id: I029e2a99013008a7c8614d63dc29df2889067d11
Diffstat (limited to 'libs/binder/IPCThreadState.cpp')
-rw-r--r-- | libs/binder/IPCThreadState.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libs/binder/IPCThreadState.cpp b/libs/binder/IPCThreadState.cpp index 0c71ed81a4..33e7d479fd 100644 --- a/libs/binder/IPCThreadState.cpp +++ b/libs/binder/IPCThreadState.cpp @@ -448,6 +448,14 @@ int32_t IPCThreadState::getLastTransactionBinderFlags() const return mLastTransactionBinderFlags; } +void IPCThreadState::setCallRestriction(ProcessState::CallRestriction restriction) { + mCallRestriction = restriction; +} + +ProcessState::CallRestriction IPCThreadState::getCallRestriction() const { + return mCallRestriction; +} + void IPCThreadState::restoreCallingIdentity(int64_t token) { mCallingUid = (int)(token>>32); |