diff options
| author | 2021-04-19 23:11:33 +0000 | |
|---|---|---|
| committer | 2021-04-20 18:21:23 +0000 | |
| commit | af816d826be5ba5703dc8c3c990ac3ab79ace7bb (patch) | |
| tree | e7a6392d6fc5d574bc7f9876df0aae08a0ffe535 /libs/gui/LayerState.cpp | |
| parent | 035c3c18c18dd2e97b833a679ab3f10f52975ac3 (diff) | |
libbinder: RPC socket bound to service thread
This is in preparation of transforming binder RPC to have a more
traditional server achitecture where the server accepts new connections,
and arbitrarily many can be added.
Before this change, there were a few issues:
- threads might call accept, but not use the FD they accepted (threads
would accidentally trade FDs, and this could create confusing logs)
- if a server thread disconnected or finished, another thread might try
to reuse the FD being used there
Now:
- server sockets are associated with the thread from the beginning
- when a connection disconnects, the server also removes the connection
Bug: 185167543
Test: binderRpcTest (note added ~RpcConnection assert)
Change-Id: Icf50a23ba52167c6fbe04ad1a77cfcb6fb3fcc9c
Diffstat (limited to 'libs/gui/LayerState.cpp')
0 files changed, 0 insertions, 0 deletions