mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
Instead of truncating iovecs when len(iovecs) > MaxReadWriteIov, we should attempt a full write. There are multiple users of hostfd: - tmpfs (when using file backend) - gofer client - hostinet - fsimpl/host These callers use hostfd to implement all read/write operations. Even though read/write syscall semantics allow for short IO, Linux seems to be doing full reads/writes. For compatibility, hostfd should attempt full IO. PiperOrigin-RevId: 582050290
21 lines
413 B
Python
21 lines
413 B
Python
load("//tools:defs.bzl", "go_library")
|
|
|
|
package(default_applicable_licenses = ["//:license"])
|
|
|
|
licenses(["notice"])
|
|
|
|
go_library(
|
|
name = "hostfd",
|
|
srcs = [
|
|
"hostfd.go",
|
|
"hostfd_linux.go",
|
|
"hostfd_unsafe.go",
|
|
],
|
|
visibility = ["//pkg/sentry:internal"],
|
|
deps = [
|
|
"//pkg/safemem",
|
|
"//pkg/sync",
|
|
"@org_golang_x_sys//unix:go_default_library",
|
|
],
|
|
)
|