diff options
Diffstat (limited to 'libs/binder/RpcState.cpp')
-rw-r--r-- | libs/binder/RpcState.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/libs/binder/RpcState.cpp b/libs/binder/RpcState.cpp index 26a2f4fa39..aa26b91274 100644 --- a/libs/binder/RpcState.cpp +++ b/libs/binder/RpcState.cpp @@ -19,8 +19,8 @@ #include "RpcState.h" #include <android-base/macros.h> -#include <android-base/scopeguard.h> #include <binder/BpBinder.h> +#include <binder/Functional.h> #include <binder/IPCThreadState.h> #include <binder/RpcServer.h> @@ -39,6 +39,8 @@ namespace android { +using namespace android::binder::impl; + #if RPC_FLAKE_PRONE void rpcMaybeWaitToFlake() { [[clang::no_destroy]] static std::random_device r; @@ -811,11 +813,11 @@ status_t RpcState::processCommand( origGuard = kernelBinderState->pushGetCallingSpGuard(&spGuard); } - base::ScopeGuard guardUnguard = [&]() { + auto guardUnguard = make_scope_guard([&]() { if (kernelBinderState != nullptr) { kernelBinderState->restoreGetCallingSpGuard(origGuard); } - }; + }); #endif // BINDER_WITH_KERNEL_IPC switch (command.command) { |