mirror of https://github.com/digint/btrbk
btrbk: correct parsing of btrfs subvolume list (allow id < top_level)
parent
8a53b3874c
commit
360deca5f2
|
@ -1,6 +1,7 @@
|
|||
btrbk-current
|
||||
|
||||
* Bugfix: fix sorting of dates in schedule().
|
||||
* Bugfix: correct parsing of btrfs subvolume list (closes: #28).
|
||||
|
||||
btrbk-0.19.2
|
||||
|
||||
|
|
10
btrbk
10
btrbk
|
@ -895,11 +895,15 @@ sub btr_tree($)
|
|||
|
||||
foreach my $node (@$subvol_list)
|
||||
{
|
||||
$id{$node->{id}} = $node;
|
||||
$uuid_info{$node->{uuid}} = $node;
|
||||
|
||||
$node->{SUBTREE} //= {};
|
||||
|
||||
$id{$node->{id}} = $node;
|
||||
$uuid_info{$node->{uuid}} = $node;
|
||||
}
|
||||
|
||||
# note: it is possible that id < top_level, e.g. after restoring
|
||||
foreach my $node (@$subvol_list)
|
||||
{
|
||||
# set SUBTREE / TOP_LEVEL node
|
||||
die unless exists($id{$node->{top_level}});
|
||||
my $top_level = $id{$node->{top_level}};
|
||||
|
|
Loading…
Reference in New Issue