Expand description
The regular-file copy ladder: reflink (CoW clone) → kernel-side copy
(fcopyfile on macOS, copy_file_range on Linux) → buffered fallback with
page-aligned I/O buffers. Each strategy writes into the caller’s temporary
path so the atomic-rename invariant is preserved.
Enums§
- Fsync
Mode - When to
fsyncfile data before the rename. - Reflink
Mode - How aggressively to attempt reflink (copy-on-write) clones.
Functions§
- copy_
file_ into - Copy
srcinto the (not-yet-existing)tmp, returning bytes written. - copy_
file_ into_ sized - Copy
srcintotmpusing a caller-specified buffer size for the fallback path. All other behavior is identical tocopy_file_into.