()
| 79 | } |
| 80 | |
| 81 | func (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 | |
| 93 | func (h *handle) Close() error { |
| 94 | h.closeOnce.Do(func() { |