From 68bc72135699fe0fc827dc3c503af2196dcd9e14 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Thu, 22 May 2008 15:38:31 +0200 Subject: [PATCH] Redirect stderr when calling ssh-keyscan This suppresses a few annoying error messages. --- dowkd.in | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dowkd.in b/dowkd.in index c0bd7bd..59c8f50 100644 --- a/dowkd.in +++ b/dowkd.in @@ -429,15 +429,15 @@ sub from_ssh_host ($@) { @addrs > 0; } @names; - my @lines= safe_backtick qw/ssh-keyscan -t/, 'rsa1,rsa,dsa', '-p', - $port, @names; + my @lines= safe_backtick_stderr qw/ssh-keyscan -t/, 'rsa1,rsa,dsa', + '-p', $port, @names; my $tmp = new File::Temp; for my $line (@lines) { - next if $line =~ /^#/; + next if $line =~ /^(?:#|no hostkey alg)/; my ($host, $data) = $line =~ /^(\S+) (.*)$/; - from_ssh_auth_line $tmp, $host, $data - or die "$host: warning: unparsable line\n"; + $host && from_ssh_auth_line $tmp, $host, $data + or die "$host: warning: unparsable line: $line"; } } -- 2.11.4.GIT