On Sat, 5 Apr 2025 at 09:07, Lionel Cons <lionelcons1972@xxxxxxxxx> wrote: > On Fri, 4 Apr 2025 at 07:07, Ron Frederick <ronf@xxxxxxxxxxxxx> wrote: > > > > On Apr 3, 2025, at 6:02 PM, Darren Tucker <dtucker@xxxxxxxxxxx> wrote: > [...] > > > Damien pointed out that it's possible to do a reasonable but not > perfect sparse file support by memcmp'ing your existing file buffer with a > block of zeros and skipping the write if it matches. OpenBSD's cp(1) does > this (look for "skipholes"): > https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/bin/cp/utils.c?annotate=HEAD > . > > This should not be done. Either a system has SEEK_DATA/SEEK_HOLE, > Win32 (Windows&ReactOS) FSCTL_QUERY_ALLOCATED_RANGES, or just copy all > bytes. If there's a protocol extension I'd like for it to be able to support other use cases, not just the one you care about. -- Darren Tucker (dtucker at dtucker.net) GPG key 11EAA6FA / A86E 3E07 5B19 5880 E860 37F4 9357 ECEF 11EA A6FA Good judgement comes with experience. Unfortunately, the experience usually comes from bad judgement. _______________________________________________ openssh-unix-dev mailing list openssh-unix-dev@xxxxxxxxxxx https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev