mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Revert "Use atomic move function on known host file in paramiko to prevent rare occurance of Control-C"
This reverts commit 642b183fb6
.
This commit is contained in:
parent
af0d8cda7b
commit
7ff63ab754
1 changed files with 1 additions and 7 deletions
|
@ -381,13 +381,7 @@ class Connection(object):
|
|||
|
||||
self.ssh.load_system_host_keys()
|
||||
self.ssh._host_keys.update(self.ssh._system_host_keys)
|
||||
|
||||
# save the new keys to a temporary file and move it into place
|
||||
# rather than rewriting the file
|
||||
tmp_keyfile = tempfile.NamedTemporaryFile()
|
||||
self._save_ssh_host_keys(tmp_keyfile)
|
||||
atomic_move(tmp_keyfile.name, self.keyfile)
|
||||
tmp_keyfile.close()
|
||||
self._save_ssh_host_keys(self.keyfile)
|
||||
|
||||
except:
|
||||
|
||||
|
|
Loading…
Reference in a new issue