Subject: kern/26155: stat(2) always returns 0 for atime
To: None <gnats-bugs@gnats.NetBSD.org>
From: Manuel Bouyer <bouyer@antioche.eu.org>
List: netbsd-bugs
Date: 07/03/2004 23:16:44
>Number: 26155
>Category: kern
>Synopsis: stat(2) always returns 0 for atime
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: kern-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Jul 03 21:17:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator: Manuel Bouyer
>Release: NetBSD 2.0_BETA, sources of Jul, 3
>Organization:
>Environment:
System: NetBSD chassiron.antioche.eu.org 2.0_BETA NetBSD 2.0_BETA (CHASSIRON) #0: Sat Jul 3 19:31:18 CEST 2004 bouyer@pop.lip6.fr:/local/pop1/bouyer/tmp/sparc/obj/local/pop1/bouyer/netbsd-2-0/src/sys/arch/sparc/compile/CHASSIRON sparc
Architecture: sparc
Machine: sparc
>Description:
This program:
#include <sys/stat.h>
main()
{
struct stat st;
while (1) {
stat("/etc/passwd", &st);
printf("size %ld atime %ld mtime %ld\n", st.st_size, st.st_atime, st.st_mtime);
sleep(10);
}
}
always return 0 for atime. Tested with file FFS and NFS.
>How-To-Repeat:
see above
>Fix:
unknown
>Release-Note:
>Audit-Trail:
>Unformatted: