Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watnot!watmath!clyde!rutgers!brl-adm!adm!sefunix%sefe.decnet@nwc-143b.arpa From: sefunix%sefe.decnet@nwc-143b.arpa Newsgroups: comp.unix.wizards Subject: Possible Bug in BSD Message-ID: <4685@brl-adm.ARPA> Date: Wed, 25-Feb-87 17:46:42 EST Article-I.D.: brl-adm.4685 Posted: Wed Feb 25 17:46:42 1987 Date-Received: Fri, 27-Feb-87 23:26:23 EST Sender: news@brl-adm.ARPA Lines: 47 We have run into a little problem on both Ultrix-32m (DEC microvax) and MT. Xinu 4.3BSD on a DEC microvax. Can someone try this program on their system and see if they also get a segmentation violation on the fopen of argv[1]. And if so, why? #include struct abc { short Red; short Green; short Blue; short Alpha; }; main (argc, argv) int argc; char **argv; { FILE *f1, *fopen(); struct abc point[151][451]; if (argc !=2) { puts("\n Usage: InputFileName \n"); exit(1); } if((f1 = fopen(argv[1], "r")) == NULL ) { printf("I can't open %s\n", argv[1]); exit(1); } fclose(f1); } ------------------------------------------------------------- Thanks, Gene Guglielmo Naval Weapons Center sefunix@nwc-143b ------