Home
last modified time | relevance | path

Searched refs:tmpfd (Results 1 – 10 of 10) sorted by relevance

/freebsd/crypto/openssh/
H A Dauth-krb5.c244 int tmpfd, ret, oerrno; in ssh_krb5_cc_gen() local
254 tmpfd = mkstemp(ccname + strlen("FILE:")); in ssh_krb5_cc_gen()
257 if (tmpfd == -1) { in ssh_krb5_cc_gen()
262 if (fchmod(tmpfd,S_IRUSR | S_IWUSR) == -1) { in ssh_krb5_cc_gen()
265 close(tmpfd); in ssh_krb5_cc_gen()
268 close(tmpfd); in ssh_krb5_cc_gen()
/freebsd/lib/libutil/
H A Duucplock.c64 int fd, tmpfd, i; in uu_lock() local
75 if ((tmpfd = open(lcktmpname, O_CREAT | O_TRUNC | O_WRONLY | O_CLOEXEC, in uu_lock()
104 if (!put_pid (tmpfd, pid)) in uu_lock()
117 (void)close(tmpfd); in uu_lock()
/freebsd/tests/sys/fs/fusefs/
H A Drename.cc43 int tmpfd = -1; member in Rename
47 if (tmpfd >= 0) { in TearDown()
48 close(tmpfd); in TearDown()
173 tmpfd = mkstemp(tmpfile); in TEST_F()
174 ASSERT_LE(0, tmpfd) << strerror(errno); in TEST_F()
/freebsd/sbin/reboot/
H A Dreboot.c119 int tmpfd; in write_nextboot() local
147 tmpfd = mkstemp(tmp); in write_nextboot()
148 if (tmpfd == -1) in write_nextboot()
151 fp = fdopen(tmpfd, "w"); in write_nextboot()
/freebsd/usr.sbin/edquota/
H A Dedquota.c107 int i, quotatype, range, tmpfd; in main() local
274 tmpfd = mkostemp(tmpfil, O_CLOEXEC); in main()
275 fchown(tmpfd, getuid(), getgid()); in main()
278 if (writetimes(protoprivs, tmpfd, quotatype) != 0 && in main()
283 close(tmpfd); in main()
292 if (writeprivs(curprivs, tmpfd, *argv, quotatype) == 0) in main()
298 close(tmpfd); in main()
/freebsd/tools/regression/security/cap_test/
H A Dcap_test_capabilities.c432 int filefd, dirfd, tmpfd; in test_capabilities() local
450 tmpfd = open("/tmp", O_RDONLY | O_DIRECTORY); in test_capabilities()
451 if (tmpfd == -1) { in test_capabilities()
554 (void)unlinkat(tmpfd, file + strlen("/tmp/"), 0); in test_capabilities()
555 (void)unlinkat(tmpfd, dir + strlen("/tmp/"), AT_REMOVEDIR); in test_capabilities()
/freebsd/contrib/libarchive/libarchive/
H A Darchive_write_disk_posix.c4170 copy_xattrs(struct archive_write_disk *a, int tmpfd, int dffd) in copy_xattrs() argument
4176 xattr_size = flistxattr(tmpfd, NULL, 0, 0); in copy_xattrs()
4190 xattr_size = flistxattr(tmpfd, xattr_names, xattr_size, 0); in copy_xattrs()
4203 s = fgetxattr(tmpfd, xattr_names + xattr_i, NULL, 0, 0, 0); in copy_xattrs()
4218 s = fgetxattr(tmpfd, xattr_names + xattr_i, xattr_val, s, 0, 0); in copy_xattrs()
4241 copy_acls(struct archive_write_disk *a, int tmpfd, int dffd) in copy_acls() argument
4249 acl = acl_get_fd(tmpfd); in copy_acls()
4280 int tmpfd; in create_tempdatafork() local
4284 tmpfd = mkstemp(tmpdatafork.s); in create_tempdatafork()
4285 if (tmpfd < 0) { in create_tempdatafork()
[all …]
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/
H A Dlibzfs_input_check.c804 int tmpfd, err; in zfs_ioc_input_tests() local
824 tmpfd = mkstemp(filepath); in zfs_ioc_input_tests()
825 if (tmpfd < 0) { in zfs_ioc_input_tests()
847 test_send_new(snapshot, tmpfd); in zfs_ioc_input_tests()
848 test_recv_new(backup, tmpfd); in zfs_ioc_input_tests()
900 (void) close(tmpfd); in zfs_ioc_input_tests()
/freebsd/contrib/elftoolchain/elfcopy/
H A Dmain.c599 int tmpfd; in copy_from_tempfile() local
621 if ((tmpfd = open(dst, O_CREAT | O_TRUNC | O_WRONLY, 0755)) < 0) in copy_from_tempfile()
624 if (elftc_copyfile(infd, tmpfd) < 0) { in copy_from_tempfile()
625 (void) close(tmpfd); in copy_from_tempfile()
634 (void) close(tmpfd); in copy_from_tempfile()
643 *outfd = tmpfd; in copy_from_tempfile()
/freebsd/contrib/capsicum-test/
H A Dcapability-fd.cc944 int tmpfd = open(tmpdir.c_str(), O_RDONLY | O_DIRECTORY); in DirOperationsTest() local
945 EXPECT_OK(tmpfd); in DirOperationsTest()
974 EXPECT_OK(unlinkat(tmpfd, "cap_dirops", AT_REMOVEDIR)); in DirOperationsTest()
975 EXPECT_OK(close(tmpfd)); in DirOperationsTest()