mirror of https://github.com/digint/btrbk
btrbk: fix btr_tree for subvolumes containing special (unsafe) characters
Note that any action (e.g. btrfs send -p) on a subvolume with unsafe characters will still fail with: ERROR: Unsafe command [...] (offending string: "/tmp/btrfs_pool/svol with spaces")pull/293/head
parent
10b826b5f3
commit
7d656540d7
2
btrbk
2
btrbk
|
@ -2278,7 +2278,7 @@ sub btr_tree($$$$)
|
|||
# "path" always starts with set REL_PATH
|
||||
my $rel_path = $node->{path};
|
||||
unless($top_level->{is_root}) {
|
||||
die unless($rel_path =~ s/^$top_level->{path}\///);
|
||||
die unless($rel_path =~ s/^\Q$top_level->{path}\E\///);
|
||||
}
|
||||
$node->{REL_PATH} = $rel_path; # relative to {TOP_LEVEL}->{path}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue