libbinder: RPC server setup debug logs
Useful while debugging vsock on host.
Bug: 185269356
Test: binderRpcTest
Change-Id: I6c7156129086c272e6863636aff378e4a000c8af
diff --git a/libs/binder/RpcServer.cpp b/libs/binder/RpcServer.cpp
index 4df12ce..de7160e 100644
--- a/libs/binder/RpcServer.cpp
+++ b/libs/binder/RpcServer.cpp
@@ -184,6 +184,8 @@
}
bool RpcServer::setupSocketServer(const RpcSocketAddress& addr) {
+ LOG_RPC_DETAIL("Setting up socket server %s", addr.toString().c_str());
+
{
std::lock_guard<std::mutex> _l(mLock);
LOG_ALWAYS_FATAL_IF(mServer.get() != -1, "Each RpcServer can only have one server.");
@@ -208,6 +210,8 @@
return false;
}
+ LOG_RPC_DETAIL("Successfully setup socket server %s", addr.toString().c_str());
+
mServer = std::move(serverFd);
return true;
}