feat: add proxy utility (#288)

Signed-off-by: Harry Li <harrymingh@gmail.com>
Co-authored-by: Dmitry Kovba <dkovba@apple.com>
This commit is contained in:
Harry Li
2025-09-12 11:23:41 -07:00
committed by GitHub
co-authored by Dmitry Kovba
parent 31bfef4a8e
commit 5fbae0e590
10 changed files with 182 additions and 16 deletions
@@ -45,7 +45,6 @@ public struct ContainerManager: Sendable {
@available(macOS 26.0, *)
public struct VmnetNetwork: Network {
private var allocator: Allocator
// `reference` isn't used concurrently.
nonisolated(unsafe) private let reference: vmnet_network_ref
/// The IPv4 subnet of this network.
@@ -95,7 +94,6 @@ public struct ContainerManager: Sendable {
public let gateway: String?
public let macAddress: String?
// `reference` isn't used concurrently.
nonisolated(unsafe) private let reference: vmnet_network_ref
public init(
@@ -480,4 +478,9 @@ extension CIDRAddress {
}
}
@available(macOS 26.0, *)
private struct SendableReference: Sendable {
nonisolated(unsafe) private let reference: vmnet_network_ref
}
#endif