summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorMartin Basti <mbasti@redhat.com>2016-03-02 17:13:27 +0100
committerTomas Babej <tbabej@redhat.com>2016-03-04 13:10:08 +0100
commit2c8e100c73ee1f0c9b57a0aabfc8ab8820e80687 (patch)
treef727ebe3dd3ba2c6829f4ce93a4b724881850050 /client
parent3c519951c5a719421d5abfa864dfeb6fbce6869d (diff)
downloadfreeipa-2c8e100c73ee1f0c9b57a0aabfc8ab8820e80687.tar.gz
freeipa-2c8e100c73ee1f0c9b57a0aabfc8ab8820e80687.tar.xz
freeipa-2c8e100c73ee1f0c9b57a0aabfc8ab8820e80687.zip
fix suspicious except statements
The "except ValueError as UnicodeDecodeError" looks very suspicious. Commit change except to catch both exceptions. https://fedorahosted.org/freeipa/ticket/5718 Reviewed-By: Tomas Babej <tbabej@redhat.com>
Diffstat (limited to 'client')
-rwxr-xr-xclient/ipa-client-install2
1 files changed, 1 insertions, 1 deletions
diff --git a/client/ipa-client-install b/client/ipa-client-install
index 1e6112445..44ddeb956 100755
--- a/client/ipa-client-install
+++ b/client/ipa-client-install
@@ -1798,7 +1798,7 @@ def update_ssh_keys(server, hostname, ssh_dir, create_sshfp):
continue
try:
pubkey = SSHPublicKey(line)
- except ValueError as UnicodeDecodeError:
+ except (ValueError, UnicodeDecodeError):
continue
root_logger.info("Adding SSH public key from %s", filename)
pubkeys.append(pubkey)