MCPcopy Create free account
hub / github.com/containerd/fifo / Path

Method Path

handle_linux.go:81–91  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

79}
80
81func (h *handle) Path() (string, error) {
82 var stat syscall.Stat_t
83 if err := syscall.Stat(h.procPath(), &stat); err != nil {
84 return "", fmt.Errorf("path %v could not be statted: %w", h.procPath(), err)
85 }
86 //nolint:unconvert
87 if uint64(stat.Dev) != h.dev || stat.Ino != h.ino {
88 return "", fmt.Errorf("failed to verify handle %v/%v %v/%v", stat.Dev, h.dev, stat.Ino, h.ino)
89 }
90 return h.procPath(), nil
91}
92
93func (h *handle) Close() error {
94 h.closeOnce.Do(func() {

Callers 2

openFifoFunction · 0.45
CloseMethod · 0.45

Calls 1

procPathMethod · 0.95

Tested by

no test coverage detected