Searched refs:dfd (Results 1 - 25 of 48) sorted by relevance

12

/freebsd-11-stable/contrib/netbsd-tests/lib/libc/c063/
H A Dt_o_search.c78 int dfd; local
85 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
87 ATF_REQUIRE((fd = openat(dfd, BASEFILE, O_RDWR, 0)) != -1);
90 ATF_REQUIRE(fchmod(dfd, 0644) == 0);
92 ATF_REQUIRE((fd = openat(dfd, BASEFILE, O_RDWR, 0)) == -1);
95 ATF_REQUIRE(close(dfd) == 0);
108 int dfd; local
115 ATF_REQUIRE((dfd = open(DIR, O_RDONLY|O_SEARCH, 0)) != -1);
117 ATF_REQUIRE((fd = openat(dfd, BASEFILE, O_RDWR, 0)) != -1);
120 ATF_REQUIRE(fchmod(dfd, 064
140 int dfd; local
174 int dfd; local
202 int dfd; local
232 int dfd; local
264 int dfd; local
283 int dfd, fd; local
305 int dfd; local
323 int dfd, fd; local
[all...]
H A Dt_fstatat.c59 int dfd; local
67 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
68 ATF_REQUIRE(fstatat(dfd, BASEFILE, &st1, 0) == 0);
69 ATF_REQUIRE(close(dfd) == 0);
115 int dfd; local
119 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
120 ATF_REQUIRE(fstatat(dfd, FILEERR, &st, 0) == -1);
121 ATF_REQUIRE(close(dfd) == 0);
131 int dfd; local
140 ATF_REQUIRE((dfd
169 int dfd; local
[all...]
H A Dt_faccessat.c59 int dfd; local
66 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
67 ATF_REQUIRE(faccessat(dfd, BASEFILE, F_OK, 0) == 0);
68 ATF_REQUIRE(close(dfd) == 0);
108 int dfd; local
111 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
112 ATF_REQUIRE(faccessat(dfd, FILEERR, F_OK, 0) == -1);
113 ATF_REQUIRE(close(dfd) == 0);
123 int dfd; local
131 ATF_REQUIRE((dfd
159 int dfd; local
[all...]
H A Dt_fchmodat.c59 int dfd; local
67 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
68 ATF_REQUIRE(fchmodat(dfd, BASEFILE, 0600, 0) == 0);
69 ATF_REQUIRE(close(dfd) == 0);
116 int dfd; local
119 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
120 ATF_REQUIRE(fchmodat(dfd, FILEERR, 0600, 0) == -1);
121 ATF_REQUIRE(close(dfd) == 0);
131 int dfd; local
139 ATF_REQUIRE((dfd
[all...]
H A Dt_unlinkat.c57 int dfd; local
64 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
65 ATF_REQUIRE(unlinkat(dfd, BASEFILE, 0) == 0);
66 ATF_REQUIRE(close(dfd) == 0);
106 int dfd; local
109 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
110 ATF_REQUIRE(unlinkat(dfd, FILEERR, 0) == -1);
111 ATF_REQUIRE(close(dfd) == 0);
121 int dfd; local
129 ATF_REQUIRE((dfd
[all...]
H A Dt_openat.c57 int dfd; local
64 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
65 ATF_REQUIRE((fd = openat(dfd, BASEFILE, O_RDONLY, 0)) != -1);
66 ATF_REQUIRE(close(dfd) == 0);
110 int dfd; local
114 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
115 ATF_REQUIRE((fd = openat(dfd, FILEERR, O_RDONLY, 0)) == -1);
116 ATF_REQUIRE(close(dfd) == 0);
126 int dfd; local
134 ATF_REQUIRE((dfd
[all...]
H A Dt_fchownat.c77 int dfd; local
88 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
89 ATF_REQUIRE(fchownat(dfd, BASEFILE, uid, gid, 0) == 0);
90 ATF_REQUIRE(close(dfd) == 0);
149 int dfd; local
155 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
156 ATF_REQUIRE(fchownat(dfd, FILEERR, uid, gid, 0) == -1);
157 ATF_REQUIRE(close(dfd) == 0);
168 int dfd; local
179 ATF_REQUIRE((dfd
212 int dfd; local
[all...]
H A Dt_utimensat.c65 int dfd; local
73 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
74 ATF_REQUIRE(utimensat(dfd, BASEFILE, tptr, 0) == 0);
75 ATF_REQUIRE(close(dfd) == 0);
128 int dfd; local
131 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
132 ATF_REQUIRE(utimensat(dfd, FILEERR, tptr, 0) == -1);
133 ATF_REQUIRE(close(dfd) == 0);
143 int dfd; local
151 ATF_REQUIRE((dfd
179 int dfd; local
[all...]
H A Dt_readlinkat.c59 int dfd; local
69 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
70 len = readlinkat(dfd, BASELINK, buf, sizeof(buf)-1);
73 ATF_REQUIRE(close(dfd) == 0);
122 int dfd; local
125 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
126 ATF_REQUIRE(readlinkat(dfd, FILEERR, F_OK, 0) == -1);
127 ATF_REQUIRE(close(dfd) == 0);
H A Dt_mkdirat.c57 int dfd; local
61 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
62 ATF_REQUIRE(mkdirat(dfd, BASESDIR, mode) != -1);
63 ATF_REQUIRE(close(dfd) == 0);
H A Dt_mkfifoat.c57 int dfd; local
61 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
62 ATF_REQUIRE(mkfifoat(dfd, BASEFIFO, mode) != -1);
64 (void)close(dfd);
H A Dt_symlinkat.c61 int dfd, fd; local
69 ATF_REQUIRE((dfd = open(NDIR, O_RDONLY, 0)) != -1);
70 ATF_REQUIRE(symlinkat(RELFILE, dfd, BASELINK) == 0);
71 ATF_REQUIRE(close(dfd) == 0);
H A Dt_mknodat.c72 int dfd; local
79 ATF_REQUIRE((dfd = open(DIR, O_RDONLY, 0)) != -1);
80 ATF_REQUIRE((fd = mknodat(dfd, BASEFILE, mode, dev)) != -1);
83 (void)close(dfd);
/freebsd-11-stable/contrib/tcsh/
H A Dtw.init.c71 DIR *dfd; /* Current directory descriptor */ member in struct:__anon42
75 #define SETDIR(dfd) \
77 tw_dir_fd = dfd; \
82 #define CLRDIR(dfd) \
83 if (dfd != NULL) { \
85 xclosedir(dfd); \
86 dfd = NULL; \
157 tw_dir_next(struct Strbuf *res, DIR *dfd) argument
161 if (dfd == NULL)
164 if ((dirp = readdir(dfd)) !
343 tw_cmd_start(DIR *dfd, const Char *pat) argument
535 tw_var_start(DIR *dfd, const Char *pat) argument
549 tw_alias_start(DIR *dfd, const Char *pat) argument
563 tw_complete_start(DIR *dfd, const Char *pat) argument
593 tw_logname_start(DIR *dfd, const Char *pat) argument
659 tw_grpname_start(DIR *dfd, const Char *pat) argument
728 tw_file_start(DIR *dfd, const Char *pat) argument
832 tw_vl_start(DIR *dfd, const Char *pat) argument
848 tw_wl_start(DIR *dfd, const Char *pat) argument
887 tw_bind_start(DIR *dfd, const Char *pat) argument
921 tw_limit_start(DIR *dfd, const Char *pat) argument
959 tw_sig_start(DIR *dfd, const Char *pat) argument
996 tw_job_start(DIR *dfd, const Char *pat) argument
[all...]
/freebsd-11-stable/contrib/netbsd-tests/fs/puffs/h_dtfs/
H A Ddtfs_subr.c85 struct dtfs_dirent *dfd; local
110 dfd = emalloc(sizeof(struct dtfs_dirent));
111 dfd->dfd_node = newpn;
112 dfd->dfd_name = estrndup(pcn->pcn_name, pcn->pcn_namelen);
113 dfd->dfd_namelen = strlen(dfd->dfd_name);
114 dfd->dfd_parent = dir;
115 dtfs_adddent(dir, dfd);
182 struct dtfs_dirent *dfd; local
187 dfd
[all...]
H A Ddtfs_vnops.c48 struct dtfs_dirent *dfd; local
64 dfd = dtfs_dirgetbyname(df, pcn->pcn_name, pcn->pcn_namelen);
65 if (dfd) {
74 puffs_newinfo_setcookie(pni, dfd->dfd_node);
75 puffs_newinfo_setvtype(pni, dfd->dfd_node->pn_va.va_type);
76 puffs_newinfo_setsize(pni, dfd->dfd_node->pn_va.va_size);
77 puffs_newinfo_setrdev(pni, dfd->dfd_node->pn_va.va_rdev);
80 puffs_flush_pagecache_node(pu, dfd->dfd_node);
376 struct dtfs_dirent *dfd; local
378 dfd
[all...]
/freebsd-11-stable/contrib/openbsm/bin/auditdistd/
H A Dtrail.c158 int dfd; local
162 dfd = dirfd(dirfp);
163 PJDLOG_ASSERT(dfd >= 0);
164 if (fstatat(dfd, filename, &sb, AT_SYMLINK_NOFOLLOW) == -1) {
207 int dfd, fd; local
221 dfd = dirfd(trail->tr_dirfp);
222 PJDLOG_ASSERT(dfd >= 0);
224 fd = openat(dfd, trail->tr_filename, O_RDONLY);
307 if (unlinkat(dfd, trail->tr_filename, 0) == -1) {
322 int dfd; local
414 int dfd; local
[all...]
/freebsd-11-stable/contrib/netbsd-tests/fs/kernfs/
H A Dt_basic.c48 int dfd; local
52 if ((dfd = rump_sys_open("/kern", O_RDONLY)) == -1)
54 if (rump_sys_getdents(dfd, buf, sizeof(buf)) == -1)
/freebsd-11-stable/sbin/gbde/
H A Dgbde.c332 cmd_open(struct g_bde_softc *sc, int dfd , const char *l_opt, u_int *nkey)
341 error = ioctl(dfd, DIOCGSECTORSIZE, &sectorsize);
344 error = ioctl(dfd, DIOCGMEDIASIZE, &mediasize);
346 error = fstat(dfd, &st);
380 cmd_nuke(struct g_bde_key *gl, int dfd , int key)
389 offset2 = lseek(dfd, offset, SEEK_SET);
392 i = write(dfd, sbuf, gl->sectorsize);
400 cmd_write(struct g_bde_key *gl, struct g_bde_softc *sc, int dfd , int key, const char *l_opt)
436 offset2 = lseek(dfd, 0, SEEK_SET);
439 i = read(dfd, sbu
519 cmd_init(struct g_bde_key *gl, int dfd, const char *f_opt, int i_opt, const char *l_opt) argument
744 int i_opt, n_opt, ch, dfd, doopen; local
[all...]
/freebsd-11-stable/libexec/rbootd/
H A Dparseconf.c312 DIR *dfd; local
328 if ((dfd = opendir(".")) == NULL) { /* open BootDir */
340 for (dp = readdir(dfd); dp != NULL; dp = readdir(dfd)) {
352 (void) closedir(dfd); /* close BootDir */
/freebsd-11-stable/sys/compat/linux/
H A Dlinux_file.c185 int dfd; local
187 dfd = (args->dfd == LINUX_AT_FDCWD) ? AT_FDCWD : args->dfd;
189 LCONVPATH_AT(td, args->filename, &path, 1, dfd);
191 LCONVPATH_AT(td, args->filename, &path, 0, dfd);
194 printf(ARGS(openat, "%i, %s, 0x%x, 0x%x"), args->dfd,
197 return (linux_common_open(td, dfd, path, args->flags, args->mode));
573 int error, dfd; local
579 dfd
626 int error, dfd; local
694 int error, dfd; local
732 int error, dfd; local
845 int error, dfd; local
892 int error, dfd; local
1526 int error, dfd, flag; local
[all...]
H A Dlinux_util.h55 #define LCONVPATH_AT(td, upath, pathp, i, dfd) \
60 pathp, i, dfd); \
69 #define LCONVPATHEXIST_AT(td, upath, pathp, dfd) LCONVPATH_AT(td, upath, pathp, 0, dfd)
71 #define LCONVPATHCREAT_AT(td, upath, pathp, dfd) LCONVPATH_AT(td, upath, pathp, 1, dfd)
/freebsd-11-stable/contrib/ofed/librdmacm/
H A Dpreload.c447 static int copysockopts(int dfd, int sfd, struct socket_calls *dapi, argument
455 ret = dapi->fcntl(dfd, F_SETFL, ret);
462 ret = dapi->setsockopt(dfd, SOL_SOCKET, SO_REUSEADDR, &param, len);
469 ret = dapi->setsockopt(dfd, IPPROTO_TCP, TCP_NODELAY, &param, len);
482 int sfd, dfd, param, ret; local
499 dfd = dapi->socket(param, SOCK_STREAM, 0);
500 if (dfd < 0)
501 return dfd;
503 ret = copysockopts(dfd, sfd, dapi, sapi);
507 fd_store(socket, dfd, new_typ
630 int sfd, dfd, ret; local
680 int lfd, sfd, dfd, ret, param; local
[all...]
/freebsd-11-stable/usr.bin/rwho/
H A Drwho.c99 int dfd; local
126 dfd = dirfd(dirp);
129 if (cap_rights_limit(dfd, &rights) < 0 && errno != ENOSYS)
144 f = openat(dfd, dp->d_name, O_RDONLY);
/freebsd-11-stable/contrib/llvm-project/compiler-rt/include/sanitizer/
H A Dlinux_syscall_hooks.h1565 #define __sanitizer_syscall_pre_mknodat(dfd, filename, mode, dev) \
1566 __sanitizer_syscall_pre_impl_mknodat((long)(dfd), (long)(filename), \
1568 #define __sanitizer_syscall_post_mknodat(res, dfd, filename, mode, dev) \
1569 __sanitizer_syscall_post_impl_mknodat(res, (long)(dfd), (long)(filename), \
1571 #define __sanitizer_syscall_pre_mkdirat(dfd, pathname, mode) \
1572 __sanitizer_syscall_pre_impl_mkdirat((long)(dfd), (long)(pathname), \
1574 #define __sanitizer_syscall_post_mkdirat(res, dfd, pathname, mode) \
1575 __sanitizer_syscall_post_impl_mkdirat(res, (long)(dfd), (long)(pathname), \
1577 #define __sanitizer_syscall_pre_unlinkat(dfd, pathname, flag) \
1578 __sanitizer_syscall_pre_impl_unlinkat((long)(dfd), (lon
[all...]

Completed in 137 milliseconds

12