diff options
author | Christian Heimes <cheimes@redhat.com> | 2015-07-14 10:50:04 +0200 |
---|---|---|
committer | Tomas Babej <tbabej@redhat.com> | 2015-07-14 13:43:50 +0200 |
commit | feb8891dd0cba60acfae16404c6bd99d0ce43075 (patch) | |
tree | 200edc1ce6b33ed0dcc838c8a60c2388b93d8b10 /ipa-client | |
parent | 334be8c9cc2a2e43cd58d83e36b21eb9def12f3a (diff) | |
download | freeipa-feb8891dd0cba60acfae16404c6bd99d0ce43075.tar.gz freeipa-feb8891dd0cba60acfae16404c6bd99d0ce43075.tar.xz freeipa-feb8891dd0cba60acfae16404c6bd99d0ce43075.zip |
Remove tuple unpacking from except clause ipa-client/ipaclient/ipachangeconf.py
Python 3 doesn't support tuple unpacking in except clauses. All implicit
tuple unpackings have been replaced with explicit unpacking of e.args.
https://fedorahosted.org/freeipa/ticket/5120
Reviewed-By: Tomas Babej <tbabej@redhat.com>
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
Diffstat (limited to 'ipa-client')
-rw-r--r-- | ipa-client/ipaclient/ipachangeconf.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ipa-client/ipaclient/ipachangeconf.py b/ipa-client/ipaclient/ipachangeconf.py index 15d41274f..edf34f5ae 100644 --- a/ipa-client/ipaclient/ipachangeconf.py +++ b/ipa-client/ipaclient/ipachangeconf.py @@ -31,13 +31,13 @@ def openLocked(filename, perms): fd = os.open(filename, os.O_RDWR | os.O_CREAT, perms) fcntl.lockf(fd, fcntl.LOCK_EX) - except OSError, (errno, strerr): + except OSError as e: if fd != -1: try: os.close(fd) except OSError: pass - raise IOError(errno, strerr) + raise IOError(e.errno, e.strerror) return os.fdopen(fd, "r+") |