Home
last modified time | relevance | path

Searched refs:rootfd (Results 1 – 5 of 5) sorted by relevance

/openbsd-src/usr.bin/rsync/
H A Duploader.c54 int rootfd; /* destination directory */ member
196 assert(p->rootfd != -1); in pre_symlink()
197 rc = fstatat(p->rootfd, f->path, &st, AT_SYMLINK_NOFOLLOW); in pre_symlink()
205 unlinkat(p->rootfd, f->path, AT_REMOVEDIR) == -1) { in pre_symlink()
218 b = symlinkat_read(p->rootfd, f->path); in pre_symlink()
244 if (mkstemplinkat(f->link, p->rootfd, temp) == NULL) { in pre_symlink()
253 p->rootfd, f, newlink ? temp : f->path); in pre_symlink()
256 if (renameat(p->rootfd, temp, p->rootfd, f->path) == -1) { in pre_symlink()
258 (void)unlinkat(p->rootfd, temp, 0); in pre_symlink()
300 assert(p->rootfd != -1); in pre_dev()
[all …]
H A Ddownloader.c66 int rootfd; /* destination directory */ member
159 unlinkat(p->rootfd, p->fname, 0); in download_cleanup()
175 const struct flist *fl, size_t flsz, int rootfd) in download_alloc() argument
187 p->rootfd = rootfd; in download_alloc()
353 p->ofd = openat(p->rootfd, f->path, O_RDONLY | O_NONBLOCK); in rsync_downloader()
422 if ((p->fd = mkstempat(p->rootfd, p->fname)) == -1) { in rsync_downloader()
563 if (renameat(p->rootfd, p->fname, p->rootfd, f->path) == -1) { in rsync_downloader()
H A Dcopy.c68 copy_file(int rootfd, const char *basedir, const struct flist *f) in copy_file() argument
72 dfd = openat(rootfd, basedir, O_RDONLY | O_DIRECTORY); in copy_file()
81 tofd = openat(rootfd, f->path, in copy_file()
H A Dreceiver.c107 rsync_set_metadata_at(struct sess *sess, int newfile, int rootfd, in rsync_set_metadata_at() argument
122 if (utimensat(rootfd, path, ts, AT_SYMLINK_NOFOLLOW) == -1) { in rsync_set_metadata_at()
142 if (fchownat(rootfd, path, uid, gid, AT_SYMLINK_NOFOLLOW) == -1) { in rsync_set_metadata_at()
158 if (fchmodat(rootfd, path, mode, AT_SYMLINK_NOFOLLOW) == -1) { in rsync_set_metadata_at()
/openbsd-src/usr.sbin/httpd/
H A Dserver_http.c1520 int rootfd, ret; in server_locationaccesstest()
1527 if ((rootfd = open(srv_conf->root, O_RDONLY)) == -1) in server_locationaccesstest()
1531 if ((ret = faccessat(rootfd, path, R_OK, 0)) != -1) in server_locationaccesstest()
1532 ret = fstatat(rootfd, path, &sb, 0);
1533 close(rootfd);
1515 int rootfd, ret; server_locationaccesstest() local