]> andersk Git - moira.git/blobdiff - backup/report.sh
update for printers table instead of printcap
[moira.git] / backup / report.sh
index 36984eb09b7f80a7ebe83e149e993d60094b8947..e13f227bb21ea445fe836afd2112e09010abbe84 100644 (file)
@@ -42,17 +42,17 @@ delete $TYPES{"NONE"};
 printf("%5d Clusters\n\n", $total);
 
 
-open(PRINTCAP, "printcap") || die "Cannot open printcap file for input.\n";
+open(PRINTERS, "printers") || die "Cannot open printers file for input.\n";
 
 $total = 0;
 
-while (<PRINTCAP>) {
-    split(/\|/, $_, 7);
-    if ($_[5]) { $auth++;  }
+while (<PRINTERS>) {
+    split(/\|/, $_, 11);
+    if ($_[9]) { $auth++; }
     $total++;
 }
 
-close(PRINTCAP);
+close(PRINTERS);
 
 printf("%5d Printers, %d with authentication (%d%%).\n\n", $total, $auth,
        (100 * $auth + $total/2)/$total);
This page took 0.196508 seconds and 4 git commands to generate.