Skip to content
Commit 73403d85 authored by Will Harris's avatar Will Harris Committed by Chromium LUCI CQ
Browse files

Create TransferableSocket mojo type and traits.

This CL adds a new mojo type and cpp implementation for a
'Transferable Socket'. This type allows transferring the socket
across process boundaries.

On Windows, this is implemented by a pairing of WSADuplicateSocket
and WSASocket on either side of the connection, with the mojo
type carrying the opaque WSA information and re-creating the
socket on the other side.

On other platforms, the socket can merely be a platform<handle>.

This CL also adds tests for the TransferableSocket, which have to
be in content as they require multi-process.

BUG=1311014

Change-Id: I6de3cb2513c7008d6f9c9038061c6e0277ba93a1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3807936


Reviewed-by: default avatarAvi Drissman <avi@chromium.org>
Commit-Queue: Will Harris <wfh@chromium.org>
Reviewed-by: default avatarYutaka Hirano <yhirano@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1041136}
parent 94c605b2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment