On Fri, 19 Apr 2002, John Summerfield wrote: > How many of these fields are absolutely critical? > > struct stat { > unsigned short st_dev; > unsigned short __pad1; > unsigned long st_ino; > unsigned short st_mode; > unsigned short st_nlink; > unsigned short st_uid; > unsigned short st_gid; > unsigned short st_rdev; > unsigned short __pad2; > unsigned long st_size; > unsigned long st_blksize; > unsigned long st_blocks; > unsigned long st_atime; > unsigned long __unused1; > unsigned long st_mtime; > unsigned long __unused2; > unsigned long st_ctime; > unsigned long __unused3; > unsigned long __unused4; > unsigned long __unused5; > }; > > I contend none of the time fields is. Not the permissions bits. A > non-written nlinks change is no worse than a failed file copy - you > don't lose data. Size? Must be consistent with the data written, but I > don't see it as more important than that. A bad nlinks might mean file data blocks are reused before all links are gone, or that data blocks are leaked because all the links vanish but the nlinks count was non-zero.