MCPcopy
hub / github.com/google/seesaw / OverrideDestination

Method OverrideDestination

engine/ipc.go:410–429  ·  view source on GitHub ↗

OverrideDestination passes a DestinationOverride to the engine.

(args *ipc.Override, reply *int)

Source from the content-addressed store, hash-verified

408
409// OverrideDestination passes a DestinationOverride to the engine.
410func (s *SeesawEngine) OverrideDestination(args *ipc.Override, reply *int) error {
411 if args == nil {
412 return errors.New("args is nil")
413 }
414 ctx := args.Ctx
415 s.trace("OverrideDestination", ctx)
416 if ctx == nil {
417 return errContext
418 }
419
420 if !ctx.CanWrite() {
421 return errAccess
422 }
423
424 if args.Destination == nil {
425 return errors.New("destination is nil")
426 }
427 s.engine.queueOverride(args.Destination)
428 return nil
429}
430
431// OverrideVserver passes a VserverOverride to the engine.
432func (s *SeesawEngine) OverrideVserver(args *ipc.Override, reply *int) error {

Callers

nothing calls this directly

Calls 3

traceMethod · 0.95
CanWriteMethod · 0.80
queueOverrideMethod · 0.45

Tested by

no test coverage detected