MCPcopy
hub / github.com/lxc/incus / HandleInvalid

Method HandleInvalid

internal/server/seccomp/seccomp.go:1263–1267  ·  view source on GitHub ↗

HandleInvalid sends a placeholder message to LXC. LXC will notice the short write and send a default message to the kernel thereby avoiding a 30s block.

(fd int, siov *Iovec)

Source from the content-addressed store, hash-verified

1261// HandleInvalid sends a placeholder message to LXC. LXC will notice the short write
1262// and send a default message to the kernel thereby avoiding a 30s block.
1263func (srv *Server) HandleInvalid(fd int, siov *Iovec) {
1264 msghdr := C.struct_msghdr{}
1265 C.sendmsg(C.int(fd), &msghdr, C.MSG_NOSIGNAL)
1266 siov.PutSeccompIovec()
1267}
1268
1269// MknodArgs arguments for mknod.
1270type MknodArgs struct {

Callers 1

NewSeccompServerFunction · 0.95

Implementers 3

ProtocolSimpleStreamsclient/simplestreams.go
ProtocolIncusclient/incus.go
ProtocolOCIclient/oci.go

Calls 1

PutSeccompIovecMethod · 0.80

Tested by

no test coverage detected