btrbk: bugfix: sort snapshots by cgen instead of PATH in action "tree"

pull/57/head
Axel Burri 2015-09-23 11:10:42 +02:00
parent 0e24738d65
commit 06bfe2a004
1 changed files with 1 additions and 1 deletions

2
btrbk
View File

@ -1980,7 +1980,7 @@ MAIN:
next if($config_subvol->{ABORTED}); next if($config_subvol->{ABORTED});
my $svol = $config_subvol->{svol} || die; my $svol = $config_subvol->{svol} || die;
push @out, "|-- $svol->{PRINT}"; push @out, "|-- $svol->{PRINT}";
foreach my $snapshot (sort { $a->{PATH} cmp $b->{PATH} } get_snapshot_children($sroot, $svol)) foreach my $snapshot (sort { $a->{cgen} cmp $b->{cgen} } get_snapshot_children($sroot, $svol))
{ {
if($snapshot->{cgen} == $svol->{gen}) { if($snapshot->{cgen} == $svol->{gen}) {
push @out, "| ^== $snapshot->{PATH}"; push @out, "| ^== $snapshot->{PATH}";