- use closedir to close directory, not just close (which is for filehandle)

This commit is contained in:
Sandro Cazzaniga 2012-07-11 13:33:12 +00:00
parent b9a20c3995
commit a0b680e8c7

View File

@ -25,7 +25,7 @@ sub available {
my $self = shift;
opendir D, $self->{dirName};
my @conf = readdir(D);
close D;
closedir D;
@conf = sort { $a <=> $b } map { /lmConf-(\d+)/ ? $1 : () } @conf;
return @conf;
}