libbinder: allow multiple outgoing threads for single-threaded
Additional outgoing threads in a single-threaded client do not actually require more threads, so they should be safe to enable. We check the number of incoming threads per RpcSession instead, since those create actual OS threads. Prevents a TOCTTOU issue between calls to setup*Client() and setMaxIncomingThreads() by adding a new mStartedSetup variable that is set early during setupClient, and any calls to RpcSession setters are fatal failures after that point. Bug: 224644083 Test: atest binderRpcTest* Change-Id: Id0ce2cda63e781ecfba86180f3c523be9044d408
Loading
Please register or sign in to comment