open.c (38452) | open.c (39672) |
---|---|
1/* $NetBSD: open.c,v 1.16 1997/01/28 09:41:03 pk Exp $ */ 2 3/*- 4 * Copyright (c) 1993 5 * The Regents of the University of California. All rights reserved. 6 * 7 * This code is derived from software contributed to Berkeley by 8 * The Mach Operating System project at Carnegie-Mellon University. --- 71 unchanged lines hidden (view full) --- 80} 81 82 83int 84open(const char *fname, int mode) 85{ 86 struct open_file *f; 87 int fd, i, error, besterror; | 1/* $NetBSD: open.c,v 1.16 1997/01/28 09:41:03 pk Exp $ */ 2 3/*- 4 * Copyright (c) 1993 5 * The Regents of the University of California. All rights reserved. 6 * 7 * This code is derived from software contributed to Berkeley by 8 * The Mach Operating System project at Carnegie-Mellon University. --- 71 unchanged lines hidden (view full) --- 80} 81 82 83int 84open(const char *fname, int mode) 85{ 86 struct open_file *f; 87 int fd, i, error, besterror; |
88 char *file; | 88 const char *file; |
89 90 if ((fd = o_gethandle()) == -1) { 91 errno = EMFILE; 92 return(-1); 93 } 94 95 f = &files[fd]; 96 f->f_flags = mode + 1; --- 41 unchanged lines hidden --- | 89 90 if ((fd = o_gethandle()) == -1) { 91 errno = EMFILE; 92 return(-1); 93 } 94 95 f = &files[fd]; 96 f->f_flags = mode + 1; --- 41 unchanged lines hidden --- |