diff --git a/scripts/list-dns-servers.ps1 b/scripts/list-dns-servers.ps1 index cf5807a6..0f780989 100755 --- a/scripts/list-dns-servers.ps1 +++ b/scripts/list-dns-servers.ps1 @@ -17,7 +17,6 @@ #> function CheckDNSServer { param($Provider, $IPv4Pri, $IPv4Sec) - Write-Progress "Measuring latency of $Provider..." $SW=[system.diagnostics.stopwatch]::startNew();$null=(nslookup fleschutz.de $IPv4Pri 2>$null);[int]$Lat1=$SW.Elapsed.TotalMilliseconds $SW=[system.diagnostics.stopwatch]::startNew();$null=(nslookup fleschutz.de $IPv4Sec 2>$null);[int]$Lat2=$SW.Elapsed.TotalMilliseconds @@ -26,12 +25,11 @@ function CheckDNSServer { param($Provider, $IPv4Pri, $IPv4Sec) } function List-DNS-Servers { - Write-Progress "Loading Data/public-dns-servers.csv..." - $Table = Import-CSV "$PSScriptRoot/../data/public-dns-servers.csv" - foreach($Row in $Table) { - CheckDNSServer $Row.PROVIDER $Row.IPv4_PRI $Row.IPv4_SEC - } - Write-Progress -completed "." + Write-Progress "Loading data/public-dns-servers.csv..." + $table = Import-CSV "$PSScriptRoot/../data/public-dns-servers.csv" + Write-Progress -completed "Done." + foreach($row in $table) { CheckDNSServer $row.PROVIDER $row.IPv4_PRI $row.IPv4_SEC } + } try {