diff options
Diffstat (limited to 'libgo/go/os/types_unix.go')
-rw-r--r-- | libgo/go/os/types_unix.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libgo/go/os/types_unix.go b/libgo/go/os/types_unix.go index 056220c..1f61481 100644 --- a/libgo/go/os/types_unix.go +++ b/libgo/go/os/types_unix.go @@ -25,3 +25,9 @@ func (fs *fileStat) Size() int64 { return fs.size } func (fs *fileStat) Mode() FileMode { return fs.mode } func (fs *fileStat) ModTime() time.Time { return fs.modTime } func (fs *fileStat) Sys() interface{} { return &fs.sys } + +func sameFile(fs1, fs2 *fileStat) bool { + return fs1.sys.Dev == fs2.sys.Dev && fs1.sys.Ino == fs2.sys.Ino +} + +const badFd = -1 |