Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!decvax!wanginst!apollo!ulowell!ametek.UUCP!walton From: walton@ametek.UUCP.UUCP Newsgroups: mod.amiga Subject: Aztec C time() and stat() Message-ID: <953@ulowell.cs.ulowell.edu> Date: Fri, 16-Jan-87 14:07:10 EST Article-I.D.: ulowell.953 Posted: Fri Jan 16 14:07:10 1987 Date-Received: Sat, 17-Jan-87 14:38:46 EST Sender: page@ulowell.cs.ulowell.edu Organization: Ametek Computer Research Div. Lines: 23 Approved: page@ulowell.cs.ulowell.edu While trying some UN*X code out on Aztec C 3.20a (including compress and the most recent mod.sources make), I discovered two facts to share: (1) The Aztec time() call returns the long integer number of seconds elapsed since 1 January 1978 00:00, and NOT the funny bit-by-bit format in the documentation, which is peculiar to MS/DOS (MicroSoft's Damaged Operating System). (2) The stat() call exists, though it is undocumented. Calling sequence is: #include stat(file, statbuf); char *file; /* name of file */ struct stat *statbuf; /* pointer to status buffer */ stat() returns the mode bits, modification time, and size of the file, as shown by the definition in stat.h. Stephen Walton ARPA: ametek!walton@csvax.caltech.edu Ametek Computer Research Div. BITNET: walton@caltech 610 N. Santa Anita Ave. UUCP: ...!ucbvax!sun!megatest!ametek!walton Arcadia, CA 91006 USA 818-445-6811