2 * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
3 * See the copyright notice in the ACK home directory, in the file "Copyright".
5 /* $Id: open.c,v 1.6 1994/06/24 11:24:37 ceriel Exp $ */
9 extern File *_get_entry();
12 sys_open(path, flag, filep)
21 if ((fp = _get_entry()) == (File *)0)
25 if ((fd = open(path, 0)) < 0)
29 if ((fd = open(path, 1)) < 0) {
30 if (access(path, 0) == 0)
34 if (lseek(fd, 0L, 2) < 0L) {
42 if ((fd = creat(path, 0666)) < 0)