mirror of
https://github.com/python/cpython.git
synced 2025-07-23 03:05:38 +00:00
Fix more exception slicing.
This commit is contained in:
parent
7357c23ee7
commit
d11b68ab08
9 changed files with 15 additions and 15 deletions
|
@ -89,8 +89,8 @@ def _toaiff(filename, temps):
|
|||
ftype = ftype[0] # All we're interested in
|
||||
except IOError as msg:
|
||||
if type(msg) == type(()) and len(msg) == 2 and \
|
||||
type(msg[0]) == type(0) and type(msg[1]) == type(''):
|
||||
msg = msg[1]
|
||||
type(msg.args[0]) == type(0) and type(msg.args[1]) == type(''):
|
||||
msg = msg.args[1]
|
||||
if type(msg) != type(''):
|
||||
msg = repr(msg)
|
||||
raise error(filename + ': ' + msg)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue