Cygwin: access: Fix X_OK behaviour for backup operators and admins
[newlib-cygwin.git] / newlib / libc / sys / mmixware / creat.c
blob622dcfad246a2cff6baf38de90ad534f19dd5165
1 /* creat for MMIXware.
3 Copyright (C) 2001 Hans-Peter Nilsson
5 Permission to use, copy, modify, and distribute this software is
6 freely granted, provided that the above copyright notice, this notice
7 and the following disclaimer are preserved with no changes.
9 THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
10 IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
11 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
12 PURPOSE. */
14 #include <_ansi.h>
15 #include <fcntl.h>
16 #include <sys/types.h>
17 #include <sys/stat.h>
18 #include "sys/syscall.h"
19 #include <errno.h>
21 int
22 creat (const char *path,
23 /* We can't set the mode, so we have to ignore it. */
24 mode_t mode)
26 return open (path, O_CREAT|O_WRONLY|O_TRUNC);