github.com/slspeek/camlistore_namedsearch@v0.0.0-20140519202248-ed6f70f7721a/cmd/camput/stat_linux.go (about) 1 //+build linux 2 3 // TODO: move this to somewhere generic in osutil; use it for all 4 // posix-y operation systems? Or rather, don't clean bad fields, but 5 // provide a portable way to extract all good fields. 6 7 package main 8 9 import ( 10 "syscall" 11 ) 12 13 func init() { 14 cleanSysStat = func(si interface{}) interface{} { 15 st, ok := si.(*syscall.Stat_t) 16 if !ok { 17 return si 18 } 19 st.Atim = syscall.Timespec{} 20 return st 21 } 22 }