Repository navigation
Conversation
upstream util1.c:1625 handle_partial_dir() creates the staging dir with do_mkdir_at(dir, 0700). The network receiver's disk-commit path passed 0777, so the dir came out 755 under umask 022 on push and pull, where 3.5.1 makes it 700. The --backup-dir parents keep ACCESSPERMS (backup.c:128, util1.c:241).
This was referenced Nov 3, 2026
Owner
Author
|
Folded into #8304 (merge commit on fix/receiver-fatal-io-lines) so both land in one CI run. |
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
upstream
util1.c:1625handle_partial_dir(..., PDIR_CREATE)creates the staging directory withdo_mkdir_at(dir, 0700), and reuses an existing directory without a chmod (:1616-1624). The network receiver's disk-commit path (disk_commit/process/commit.rs) created it throughcreate_dir_all_sandboxed(.., 0o777). Under umask 022 that gave 755 on push and pull, where 3.5.1 gives 700. The local engine and the abort-time partial keep were already 0700.create_dir_all_sandboxednow takes the mode. The staging dir passes 0o700. The--backup-dirparents keep 0o777, matching upstream ACCESSPERMS (backup.c:128,util1.c:241).Oracle (rsync 3.5.1 tarball build, umask 022, interrupted -r transfer, stat of the staging dir)
Tests
disk_commit::tests::staging_dir_mode(unix):delay_updates_creates_the_partial_dir_0700: a new staging dir is 0700.delay_updates_keeps_an_existing_partial_dir_mode: an existing 0751 dir stays 0751, as upstream skips the mkdir and never chmods.Each mutation is killed by exactly one test:
Gates: rustfmt-all passes. Workspace clippy with
-D warningsis clean. Running nextest onpackage(transfer) & (delay_updates | partial_dir | backup)gives 163/163 passed.Not in this PR
--serverreceiver whose client dies mid-file keeps no partial; upstream keeps it on exit (cleanup.c:159-181). Tracked separately.receiver.c:1318-1325) is task 523.