mirror of
https://github.com/speed47/btrfs-list
synced 2024-09-28 20:03:32 +00:00
fix: bad indent when --indent was != 3 (fixes #19)
This commit is contained in:
parent
99a6cfdfd1
commit
0264500d22
|
@ -413,7 +413,7 @@ if ($opt_max_name_len > 0 && $opt_max_name_len < 4) {
|
|||
$opt_max_name_len = 4;
|
||||
}
|
||||
|
||||
$opt_indent //= 4;
|
||||
$opt_indent //= 3;
|
||||
|
||||
if (defined $opt_profile && $opt_profile !~ /^(raid([0156]|1c[34]|10)|single|dup)$/) {
|
||||
print STDERR "FATAL: invalid argument for --profile\n";
|
||||
|
@ -1002,7 +1002,7 @@ sub longest {
|
|||
|
||||
# loop through all the items
|
||||
foreach my $item (@orderedAll) {
|
||||
my $len = ($useDepth ? (($item->{depth} || 0) * 3) : 0);
|
||||
my $len = ($useDepth ? (($item->{depth} || 0) * $opt_indent) : 0);
|
||||
$len += length($item->{$key} || '');
|
||||
$longest = $len if $len > $longest;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue