now passes the perl compile time check
authorHeiko Schlittermann <hs@schlittermann.de>
Mon, 02 Aug 2010 15:50:54 +0200
changeset 8 654be00c18ee
parent 0 99443200522e
child 9 7ca31b207366
now passes the perl compile time check
update-serial
--- a/update-serial	Fri Jan 18 21:41:31 2008 +0000
+++ b/update-serial	Mon Aug 02 15:50:54 2010 +0200
@@ -10,6 +10,9 @@
 #   the current directory)
 # . optionally reload the named
 
+use strict;
+use warnings;
+
 use File::Basename;
 use File::Copy;
 my $ME = basename $0;
@@ -17,11 +20,12 @@
 my $verbose = 0;
 my $opt_yes = 0;
 
+
 sub cleanup() { unlink @tmpfiles; }
 END { cleanup(); }
 
 $ARGV[0] eq "-y" and $opt_yes = 1, shift;
-@Zones = @ARGV ? @ARGV : </etc/bind/p/*>;
+my @Zones = @ARGV ? @ARGV : </etc/bind/p/*>;
 
 
 MAIN: {
@@ -35,7 +39,7 @@
 	$date = "$yy$mm$dd";
 
 
-	while ($file = shift @Zones) {
+	while (my $file = shift @Zones) {
 		local (*I, *O);
 		my $done = 0;