chiark / gitweb /
@@ -2,7 +2,7 @@
[chiark-utils.git] / scripts / named-conf
index 6d1777550253a274eea2dc3440a30587f0e8f61b..ba36757a41a33b4504e38dbd4bd9b34a38c460d4 100755 (executable)
@@ -360,8 +360,10 @@ sub zone_investigate() {
        $super_zone= $zone;
        for (;;) {
            debug_trace("zone $zone superzone $super_zone");
+           $super_zone eq '.'
+               and die "no superzone ? ($super_zone)\n";
            $super_zone =~ s/^[^.]+\.//
-               or die "no superzone ? ($super_zone)\n";
+               or $super_zone= '.';
            ($rcode,@start_nsnames)=
                lookup($super_zone,'ns-','06',"superzone search");
            last if !$rcode;
@@ -429,7 +431,7 @@ sub zone_check_nsrrset ($$$$) {
        if (!@glue) {
            zone_warning("glueless NS $s", $ww)
                unless $glueless_ok || !$needglue ||
-                      grep { has_suffix_of($s,".$_"); }
+                      grep { has_suffix_of($zone,".$_"); }
                           @{ $cfg->{'conv_glueless'} };
            ($rcode,@glue)= lookup($s,'a','0',"glueless NS from $ww");
            foreach $a (@glue) {
@@ -698,7 +700,7 @@ sub lookup ($$$$) {
     defined($c= open $h, "-|") or die "$quis: fork adnshost:\n $!\n";
     if (!$c) {
        exec 'adnshost','-Fi','+Do','+Dt','+Dc','-Cf',"-t$type",
-            '-',"$domain.";
+            '-',"$domain";
        die "$quis: exec adnshost:\n $!\n";
     }
     @result= $h->getlines();