Fixed problem when specified partition, print return data not correct

(cherry picked from commit 60150ab8dd137c280f0f7a25d5ea924e273750f8)
This commit is contained in:
m-lopez-f 2015-01-26 09:57:28 +01:00
parent 0e70a8899a
commit 2c985653fb

View File

@ -34,7 +34,7 @@ if ($#ARGV < 0) {
# Parse command line parameters # Parse command line parameters
my %filesystems; my %filesystems;
foreach my $fs (@ARGV) { foreach my $fs (@ARGV) {
$filesystems{$fs} = '-1%'; $filesystems{$fs} = '0%';
} }
# Retrieve filesystem information # Retrieve filesystem information
@ -51,7 +51,7 @@ if ($#df < 0) {
foreach my $row (@df) { foreach my $row (@df) {
my @columns = split (' ', $row); my @columns = split (' ', $row);
exit 1 if ($#columns < 4); exit 1 if ($#columns < 4);
$filesystems{$columns[5]} = $columns[4] if (defined ($filesystems{$columns[0]}) || $all_filesystems == 1); $filesystems{$columns[5]} = $columns[4] if (defined ($filesystems{$columns[5]}) || $all_filesystems == 1);
} }
my $free; my $free;