Explorar el Código

dpkg-scanpackages: Use a scalar variable instead of an IO::Handle

Guillem Jover hace 11 años
padre
commit
f2dad32eb5
Se han modificado 1 ficheros con 1 adiciones y 3 borrados
  1. 1 3
      scripts/dpkg-scanpackages.pl

+ 1 - 3
scripts/dpkg-scanpackages.pl

@@ -20,7 +20,6 @@
 use warnings;
 use strict;
 
-use IO::Handle;
 use Getopt::Long qw(:config posix_default bundling no_ignorecase);
 
 use Dpkg ();
@@ -253,8 +252,7 @@ if (defined $override and not -e $override) {
 
 $pathprefix //= '';
 
-my $find_h = IO::Handle->new();
-open($find_h, '-|', 'find', '-L', "$binarydir/", @find_args, '-print')
+open my $find_h, '-|', 'find', '-L', "$binarydir/", @find_args, '-print'
      or syserr(g_("couldn't open %s for reading"), $binarydir);
 while (my $fn = <$find_h>) {
     chomp $fn;