Fixes bug #10225 - Runtime error

Prevents an exception from raising in some corner cases where SSH might
be misconfigured. It seems not to fix a specific problem, although it
makes the method a little bit more solid.
pull/10315/head
Alvaro Lopez Ortega 10 years ago
parent 1cb47c807e
commit 2dc910bd14

@ -237,6 +237,8 @@ class Connection(ConnectionBase):
if line is None or " " not in line:
continue
tokens = line.split()
if not tokens:
continue
if tokens[0].find(self.HASHED_KEY_MAGIC) == 0:
# this is a hashed known host entry
try:

Loading…
Cancel
Save