Skip to content

Commit 22795fe

Browse files
Hasini Gunasingheandroid-build-merge-worker-robot
authored andcommitted
Merge "Implement Send for RpcServerConnection" into main am: c643576
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/3398707 Change-Id: Ie59c0d96d355b2ba307e38fe66d72a1239cf5d0f Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2 parents 7e6be23 + c643576 commit 22795fe

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

  • libs/binder/rust/rpcbinder/src/server

libs/binder/rust/rpcbinder/src/server/trusty.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,10 @@ pub struct RpcServerConnection {
106106
ctx: *mut c_void,
107107
}
108108

109+
// SAFETY: The opaque handle: `ctx` points into a dynamic allocation,
110+
// and not tied to anything specific to the current thread.
111+
unsafe impl Send for RpcServerConnection {}
112+
109113
impl Drop for RpcServerConnection {
110114
fn drop(&mut self) {
111115
// We do not need to close handle_fd since we do not own it.

0 commit comments

Comments
 (0)