Close connection after each failed connect attempt

Currently the ssh lib code does not explicitly close the Transport
objects on auth failure. It is possible that paramiko is leaving the
connections open on each auth attempt which is crashing dropbear in
cirros guests. This commit adds the close() call on failure to make
sure we don't leave a dangling connection open.

Change-Id: Ida499a80be184b1af9b53d4ab27a8abbc4d59898
1 file changed