Repository navigation
fix: send a server receiver's --list-only listing to the pushing client - #8308
Merged
Merged
Conversation
oferchen
force-pushed
the
fix/push-list-only
branch
from
November 4, 2026 08:59
48222f4 to
1771125
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
oc-rsync --list-only src/ host:dst/(a push) printed nothing when the far end was an oc server or oc daemon. rsync 3.5.1 prints the listing. An oc client pushing to a 3.5.1 server already worked: the defect was on the oc server receiver.On a push the generator runs on the server, so upstream renders the listing there:
--list-onlywhen it was given explicitly (options.c:2923-2924) and moves no data.recv_generator()hands each entry tolist_file_entry()and returns (generator.c:1636-1643). The receiver never enters or writes the destination:get_local_name()returns NULL underlist_only(main.c:725).list_file_entry()formats"%s %*s %s%*s%*s %s%s%s\n"(generator.c:1318-1356). Itsrprintf(FINFO, ...)reaches the client asMSG_INFOthroughrwrite()(log.c:355-366), and a daemon also logs it.oc's server receiver collected the entries into its stats, which only a pulling client reads, and never sent them.
Fix
MSG_INFO, in the generator's walk order, through the same sink itemize lines use. A client receiver (a pull) still hands the entries back to the client to print, so the pull path is unchanged. The rendering is intransfer::receiver::list_line:server_options()never forwards-h/--no-h(options.c:2778-3190), so a server keepshuman_readable = 1(options.c:116, generator.c:1322).timestring()(util1.c:1722-1739) does there.-Uand-Nadd the atime and crtime columns, and the atime column is blank for a directory.--delete-missing-argslists a missing operand as*missing(generator.c:1331-1338).F_SYMLINK, the target asrecv_file_entry()stored it, munge prefix and sanitizing included (flist.c:1521-1524, :1553; generator.c:1345). The oracle found this one: ause chroot = nomodule munges symlinks by default, so 3.5.1 listslink -> /rsyncd-munged/a.txt. The listing previously showed the raw target.permstring()(lib/permstring.c), the comma grouping ofdo_big_num()(lib/compat.c) andtimestring()move intologging::upstream_text. The daemon%Bfield, the log-file timestamp and the cli size column now call them, and their own copies are removed.transfergainsplatformas a normal dependency for the local zone offset.Oracle
crates/transfer/tests/push_list_only_reaches_client.rs. Every expected listing is the verbatim stdout of the rsync 3.5.1 tarball build on the same fixture, withTZ=UTCon both ends; only directory sizes are blanked. When 3.5.1 is installed, each cell also runs the other client/server pairings and requires byte-identical output.-rland-r-rl(use chroot = no)-rl(control)Mutations
Each mutation was applied to the committed fix and the named tests were run.
list_lineandcomma_numunit testspermstringgives a symlink type-permstring_matches_upstreamtimestringyear off by oneA sixth mutation forced the
-larrow on. It survived, because without-lthe sender sends no target, so that check could never change the output. The check was removed rather than kept as dead code.Gates
fmt,
check_rustfmt_all.py, workspace clippy with-D warnings, the windows-gnu workspace check, and the oracle above, run against the 3.5.1 tarball build.