Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!decvax!decwrl!ucbvax!DHDEMBL5.BITNET!MANSFIELD From: MANSFIELD@DHDEMBL5.BITNET.UUCP Newsgroups: mod.computers.vax Subject: problem with C fopen(), file revision date Message-ID: <8606030621.AA27089@ucbvax.Berkeley.EDU> Date: Mon, 2-Jun-86 11:39:41 EDT Article-I.D.: ucbvax.8606030621.AA27089 Posted: Mon Jun 2 11:39:41 1986 Date-Received: Tue, 3-Jun-86 21:31:41 EDT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet Lines: 26 Approved: info-vax@sri-kl.arpa The following program behaves curiously. When you run it, the revision date of the file it opens is updated, if that file is a stream_lf file. If the file is variable length or fixed length, the revision date is not updated. This even occurs when the file protection is (s,o,g,w:r), and the file is on a directory which is not mine. Any explanations? #include main(argc, argv) int argc; char **argv; { FILE *inf; char line[BUFSIZ]; argc--; argv++; if ( (inf = fopen(*argv, "r")) != NULL) puts("Opened"); else puts("Can't open"); }