github.com/pkg/sftp@v1.13.6/request-unix.go (about) 1 //go:build !windows && !plan9 2 // +build !windows,!plan9 3 4 package sftp 5 6 import ( 7 "errors" 8 "syscall" 9 ) 10 11 func fakeFileInfoSys() interface{} { 12 return &syscall.Stat_t{Uid: 65534, Gid: 65534} 13 } 14 15 func testOsSys(sys interface{}) error { 16 fstat := sys.(*FileStat) 17 if fstat.UID != uint32(65534) { 18 return errors.New("Uid failed to match") 19 } 20 if fstat.GID != uint32(65534) { 21 return errors.New("Gid failed to match") 22 } 23 return nil 24 }