Skip to content

Commit d92ca2d

Browse files
authored
fix: Set correct content for symlink with parent snapshot (#174)
When having a symlink which is already present in a parent snapshot, rustic set `content = []` instead of using the parent content. While this does no harm (for symlinks the content is anyway not read), it may lead to changed trees even though no change was actually performed. This PR fixes that.
1 parent 87fb602 commit d92ca2d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/core/src/archiver/parent.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ impl Parent {
279279
let parent = match parent {
280280
ParentResult::Matched(p_node) => {
281281
if p_node.content.iter().flatten().all(|id| index.has_data(id)) {
282-
node.content = Some(p_node.content.iter().flatten().copied().collect());
282+
node.content = p_node.content.clone();
283283
ParentResult::Matched(())
284284
} else {
285285
warn!(

0 commit comments

Comments
 (0)