Lines Matching refs:disk_fd
28 safe_close(j->disk_fd); in pull_job_close_disk_fd()
30 j->disk_fd = -1; in pull_job_close_disk_fd()
246 if (j->disk_fd >= 0) { in pull_job_curl_on_finished()
255 if (ftruncate(j->disk_fd, j->written_uncompressed) < 0) { in pull_job_curl_on_finished()
262 … (void) fsetxattr(j->disk_fd, "user.source_etag", j->etag, strlen(j->etag), 0); in pull_job_curl_on_finished()
264 … (void) fsetxattr(j->disk_fd, "user.source_url", j->url, strlen(j->url), 0); in pull_job_curl_on_finished()
271 … if (futimens(j->disk_fd, (struct timespec[]) { ut, ut }) < 0) in pull_job_curl_on_finished()
274 r = fd_setcrtime(j->disk_fd, j->mtime); in pull_job_curl_on_finished()
281 r = fsync_full(j->disk_fd); in pull_job_curl_on_finished()
290 if (fsync(j->disk_fd) < 0) { in pull_job_curl_on_finished()
329 if (j->disk_fd >= 0) { in pull_job_write_uncompressed()
334 n = sparse_write(j->disk_fd, p, sz, 64); in pull_job_write_uncompressed()
340 r = loop_write(j->disk_fd, p, sz, false); in pull_job_write_uncompressed()
346 if (j->disk_fd < 0 || j->force_memory) { in pull_job_write_uncompressed()
414 if (j->disk_fd >= 0) { in pull_job_open_disk()
415 if (fstat(j->disk_fd, &j->disk_stat) < 0) in pull_job_open_disk()
419 if (lseek(j->disk_fd, j->offset, SEEK_SET) == (off_t) -1) in pull_job_open_disk()
700 .disk_fd = -1, in pull_job_new()