Home
last modified time | relevance | path

Searched refs:oflags (Results 1 – 25 of 143) sorted by relevance

123456

/src/contrib/openbsm/libbsm/
H A Dbsm_io.c462 print_tok_type(FILE *fp, u_char type, const char *tokname, int oflags) in print_tok_type() argument
465 if (oflags & AU_OFLAG_XML) { in print_tok_type()
632 if (oflags & AU_OFLAG_RAW) in print_tok_type()
643 print_user(FILE *fp, u_int32_t usr, int oflags) in print_user() argument
647 if (oflags & (AU_OFLAG_RAW | AU_OFLAG_NORESOLVE)) in print_user()
662 print_group(FILE *fp, u_int32_t grp, int oflags) in print_group() argument
666 if (oflags & (AU_OFLAG_RAW | AU_OFLAG_NORESOLVE)) in print_group()
682 print_event(FILE *fp, u_int16_t ev, int oflags) in print_event() argument
700 if (oflags & AU_OFLAG_RAW) in print_event()
702 else if (oflags & AU_OFLAG_SHORT) in print_event()
[all …]
/src/lib/libc/tests/stdio/
H A Dmkostemp_test.c49 test_one(int oflags) in test_one() argument
56 fd = mkostemp(tmpf, oflags); in test_one()
60 testnum++, oflags, strerror(errno)); in test_one()
66 testnum++, oflags, tmpf); in test_one()
71 (oflags & O_CLOEXEC ? FD_CLOEXEC : 0)) { in test_one()
74 testnum++, oflags); in test_one()
77 if ((fcntl(fd, F_GETFL) & MISCFLAGS) != (oflags & MISCFLAGS)) { in test_one()
80 testnum++, oflags); in test_one()
86 testnum++, oflags, tmpf, strerror(errno)); in test_one()
92 testnum++, oflags, fd, strerror(errno)); in test_one()
[all …]
/src/contrib/sendmail/libsm/
H A Dstdio.c67 int oflags; local
72 oflags = O_RDWR;
75 oflags = O_RDWR | O_CREAT | O_TRUNC;
78 oflags = O_RDONLY;
81 oflags = O_WRONLY | O_CREAT | O_TRUNC;
84 oflags = O_APPEND | O_WRONLY | O_CREAT;
87 oflags = O_APPEND | O_RDWR | O_CREAT;
95 oflags |= O_BINARY;
97 fp->f_file = open(path, oflags,
102 if (oflags & O_APPEND)
[all …]
/src/contrib/openbsm/bin/praudit/
H A Dpraudit.c68 static int oflags = AU_OFLAG_NONE; variable
107 au_print_flags_tok(stdout, &tok, del, oflags); in print_tokens()
110 if (!(oflags & AU_OFLAG_XML)) in print_tokens()
145 oflags |= AU_OFLAG_NORESOLVE; in main()
153 if (oflags & AU_OFLAG_SHORT) in main()
155 oflags |= AU_OFLAG_RAW; in main()
159 if (oflags & AU_OFLAG_RAW) in main()
161 oflags |= AU_OFLAG_SHORT; in main()
165 oflags |= AU_OFLAG_XML; in main()
186 if (oflags & AU_OFLAG_XML) in main()
[all …]
/src/lib/libc/stdio/
H A Dmktemp.c52 mkostempsat(int dfd, char *path, int slen, int oflags) in mkostempsat() argument
56 return (_gettemp(dfd, path, &fd, 0, slen, oflags) ? fd : -1); in mkostempsat()
60 mkostemps(char *path, int slen, int oflags) in mkostemps() argument
64 return (_gettemp(AT_FDCWD, path, &fd, 0, slen, oflags) ? fd : -1); in mkostemps()
76 mkostemp(char *path, int oflags) in mkostemp() argument
80 return (_gettemp(AT_FDCWD, path, &fd, 0, 0, oflags) ? fd : -1); in mkostemp()
113 _gettemp(int dfd, char *path, int *doopen, int domkdir, int slen, int oflags) in _gettemp() argument
123 (oflags & ~(O_APPEND | O_DIRECT | O_SHLOCK | O_EXLOCK | O_SYNC | in _gettemp()
150 oflags |= O_CREAT | O_EXCL | O_RDWR; in _gettemp()
153 *doopen = _openat(dfd, path, oflags, 0600); in _gettemp()
H A Dfreopen.c58 int dflags, fdflags, flags, isopen, oflags, sverrno, wantfd; in freopen() local
60 if ((flags = __sflags(mode, &oflags)) == 0) { in freopen()
93 (dflags & (O_ACCMODE | O_EXEC)) != (oflags & O_ACCMODE)) { in freopen()
101 if ((oflags ^ dflags) & O_APPEND) { in freopen()
103 dflags |= oflags & O_APPEND; in freopen()
112 if (oflags & O_TRUNC) in freopen()
114 if (!(oflags & O_APPEND)) in freopen()
116 if ((oflags & O_CLOEXEC) != 0) { in freopen()
153 f = _open(file, oflags, DEFFILEMODE); in freopen()
160 f = _open(file, oflags, DEFFILEMODE); in freopen()
[all …]
H A Dfdopen.c49 int flags, oflags, fdflags, rc, tmp; in fdopen() local
63 if ((flags = __sflags(mode, &oflags)) == 0) in fdopen()
71 if (tmp != O_RDWR && (tmp != (oflags & O_ACCMODE))) { in fdopen()
79 if ((oflags & O_CLOEXEC) != 0) { in fdopen()
102 else if (oflags & O_APPEND) in fdopen()
H A Dfopen.c52 int flags, oflags; in fopen() local
54 if ((flags = __sflags(mode, &oflags)) == 0) in fopen()
58 if ((f = _open(file, oflags, DEFFILEMODE)) < 0) { in fopen()
90 if (oflags & O_APPEND) { in fopen()
H A Dfopencookie.c52 int flags, oflags; in fopencookie() local
54 if ((flags = __sflags(mode, &oflags)) == 0) in fopencookie()
78 if ((oflags & O_APPEND) != 0) in fopencookie()
/src/usr.bin/tee/
H A Dtee.c65 int append, ch, exitval, fd, n, oflags, rval, wval; in main() local
92 oflags = O_WRONLY | O_CREAT; in main()
94 oflags |= O_APPEND; in main()
96 oflags |= O_TRUNC; in main()
99 if ((fd = tee_open(*argv, oflags)) < 0) { in main()
157 tee_open(const char *path, int oflags) in tee_open() argument
163 if ((fd = open(path, oflags, DEFFILEMODE)) >= 0) in tee_open()
/src/crypto/openssh/openbsd-compat/
H A Dbsd-misc.c133 int ret, oflags = O_WRONLY; in utimensat() local
150 oflags |= O_NOFOLLOW; in utimensat()
152 if ((fd = open(path, oflags)) == -1) in utimensat()
170 int ret, oflags = O_WRONLY; in fchownat() local
181 oflags |= O_NOFOLLOW; in fchownat()
183 if ((fd = open(path, oflags)) == -1) in fchownat()
201 int ret, oflags = O_WRONLY; in fchmodat() local
212 oflags |= O_NOFOLLOW; in fchmodat()
214 if ((fd = open(path, oflags)) == -1) in fchmodat()
/src/sys/security/audit/
H A Daudit_bsm_klib.c209 audit_flags_and_error_to_openevent(int oflags, int error) in audit_flags_and_error_to_openevent() argument
216 oflags = oflags & (O_RDONLY | O_CREAT | O_TRUNC | O_RDWR | O_WRONLY); in audit_flags_and_error_to_openevent()
218 if (aue_open[i].aoe_flags == oflags) in audit_flags_and_error_to_openevent()
225 audit_flags_and_error_to_openatevent(int oflags, int error) in audit_flags_and_error_to_openatevent() argument
232 oflags = oflags & (O_RDONLY | O_CREAT | O_TRUNC | O_RDWR | O_WRONLY); in audit_flags_and_error_to_openatevent()
234 if (aue_openat[i].aoe_flags == oflags) in audit_flags_and_error_to_openatevent()
/src/lib/libc/gen/
H A Dmemfd_create.c57 int error, fd, npgs, oflags, pgidx, saved_errno, shmflags; in memfd_create() local
81 oflags = O_RDWR; in memfd_create()
84 oflags |= O_CLOEXEC; in memfd_create()
91 fd = __sys_shm_open2(SHM_ANON, oflags, 0, shmflags, memfd_name); in memfd_create()
/src/sys/contrib/openzfs/tests/zfs-tests/tests/functional/direct/
H A Ddio_mixed.ksh71 oflags=""
79 oflags="-D"
92 -c $oblocks $oflags
100 -c $oblocks $oflags
/src/bin/dd/
H A Ddd.c135 int iflags, oflags; in setup() local
170 oflags = fcntl(out.fd, F_GETFL); in setup()
171 if (oflags == -1) in setup()
173 oflags |= O_FSYNC; in setup()
174 if (fcntl(out.fd, F_SETFL, oflags) == -1) in setup()
178 oflags = O_CREAT; in setup()
180 oflags |= O_TRUNC; in setup()
182 oflags |= O_FSYNC; in setup()
184 oflags |= O_DIRECT; in setup()
186 out.fd = open(out.name, O_RDWR | oflags, DEFFILEMODE); in setup()
[all …]
/src/sys/fs/fuse/
H A Dfuse_file.h182 int oflags = -1; in fufh_type_2_fflags() local
189 oflags = type; in fufh_type_2_fflags()
195 return oflags; in fufh_type_2_fflags()
/src/usr.bin/truncate/
H A Dtruncate.c56 int ch, error, fd, oflags, r; in main() local
147 oflags = O_WRONLY; in main()
149 oflags = O_WRONLY | O_CREAT; in main()
155 if ((fd = open(fname, oflags, omode)) == -1) { in main()
/src/sys/sys/
H A Dfcntl.h176 #define FFLAGS(oflags) ((oflags) & O_EXEC ? (oflags) : (oflags) + 1) argument
/src/tests/sys/ses/
H A Dcommon.h30 for_each_ses_dev(ses_cb cb, int oflags) in for_each_ses_dev() argument
48 fd = open(g.gl_pathv[i], oflags); in for_each_ses_dev()
/src/bin/sh/
H A Dmain.c249 int oflags = O_RDONLY | O_CLOEXEC; in read_profile() local
252 oflags |= O_VERIFY; in read_profile()
258 if ((fd = open(expandedname, oflags)) >= 0) in read_profile()
/src/contrib/ntp/ntpd/
H A Dntp_ppsdev.c388 int oflags ) /* openn flags for pps device */ in ppsdev_reopen() argument
398 (void)oflags; in ppsdev_reopen()
406 retfd = open(ppspath, omode, oflags); in ppsdev_reopen()
417 retfd = open(xpath, omode, oflags); in ppsdev_reopen()
/src/sys/kern/
H A Dcoredump_vnode.c213 int error, i, flags, oflags, cmode; in corefile_open_last() local
219 oflags = VN_OPEN_NOAUDIT | VN_OPEN_NAMECACHE | in corefile_open_last()
231 error = vn_open_cred(&nd, &flags, cmode, oflags, td->td_ucred, in corefile_open_last()
311 int cmode, error, flags, i, indexpos, indexlen, oflags, ncores; in corefile_open() local
399 oflags = VN_OPEN_NOAUDIT | VN_OPEN_NAMECACHE | in corefile_open()
406 error = vn_open_cred(&nd, &flags, cmode, oflags, td->td_ucred, in corefile_open()
/src/sys/net80211/
H A Dieee80211_crypto.c344 int oflags; in ieee80211_crypto_newkey() local
386 oflags = key->wk_flags; in ieee80211_crypto_newkey()
389 flags |= (oflags & IEEE80211_KEY_DEVICE); in ieee80211_crypto_newkey()
447 key->wk_flags = oflags; /* restore old flags */ in ieee80211_crypto_newkey()
485 oflags, IEEE80211_KEY_BITS, in ieee80211_crypto_newkey()
493 key->wk_flags = oflags; /* restore old flags */ in ieee80211_crypto_newkey()
/src/contrib/ncurses/ncurses/trace/
H A Dlib_tracebits.c127 }, oflags[] = in _nc_trace_ttymode() local
167 8 + sizeof(oflags) + in _nc_trace_ttymode()
177 lookup_bits(buf, oflags, "oflags", tty->c_oflag); in _nc_trace_ttymode()
/src/sys/vm/
H A Dvm_page.c1345 m->oflags = VPO_UNMANAGED; in vm_page_initfake()
1363 KASSERT((m->oflags & VPO_UNMANAGED) != 0, ("managed %p", m)); in vm_page_putfake()
1645 KASSERT(((m->oflags & VPO_UNMANAGED) != 0) == in vm_page_free_object_prep()
1892 KASSERT((mold->oflags & VPO_UNMANAGED) == in vm_page_replace_hold()
1893 (mnew->oflags & VPO_UNMANAGED), in vm_page_replace_hold()
2186 m->oflags = (object->flags & OBJ_UNMANAGED) != 0 ? VPO_UNMANAGED : 0; in vm_page_alloc_domain_iter()
2206 m->oflags = VPO_UNMANAGED; in vm_page_alloc_domain_iter()
2344 u_int busy_lock, flags, oflags; in vm_page_alloc_contig_domain() local
2386 oflags = (object->flags & OBJ_UNMANAGED) != 0 ? VPO_UNMANAGED : 0; in vm_page_alloc_contig_domain()
2407 m->oflags = oflags; in vm_page_alloc_contig_domain()
[all …]

123456