Subject: | Net::DNS::Resolver::Base should use 3 args open |
Suggested patch for the Base.pm
note that we should also consider patching
- Resolver/cygwin.pm
- Resolver/os390.pm
Subject: | 3args.patch |
+index db93167ed..f30e528f1 100644
+--- a/Net/DNS/Resolver/Base.pm
++++ b/Net/DNS/Resolver/Base.pm
+@@ -176,14 +176,14 @@ sub _read_config_file { ## read resolver config file
+ my $self = shift;
+ my $file = shift;
+
+- local *FILE;
+- open( FILE, $file ) or croak "$file: $!";
++ my $fh;
++ open( $fh, '<', $file ) or croak "$file: $!";
+
+ my @nameserver;
+ my @searchlist;
+
+ local $_;
+- while (<FILE>) {
++ while (<$fh>) {
+ s/[;#].*$//; # strip comments
+
+ /^nameserver/ && do {
+@@ -212,7 +212,7 @@ sub _read_config_file { ## read resolver config file
+ };
+ }
+
+- close(FILE);
++ close($fh);
+
+ $self->nameservers(@nameserver) if @nameserver;
+ $self->searchlist(@searchlist) if @searchlist;