summaryrefslogtreecommitdiffstats
path: root/storage/__init__.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2009-04-23 13:01:35 -0400
committerChris Lumens <clumens@redhat.com>2009-04-23 14:17:14 -0400
commitcfac7bcb2079b463e33c2401002575d0de12d9b2 (patch)
tree488fb8e49604b3245dca24961fda684888bd56d8 /storage/__init__.py
parent11bbfaa2b00d1a212462c689834a9179b15cb843 (diff)
downloadanaconda-cfac7bcb2079b463e33c2401002575d0de12d9b2.tar.gz
anaconda-cfac7bcb2079b463e33c2401002575d0de12d9b2.tar.xz
anaconda-cfac7bcb2079b463e33c2401002575d0de12d9b2.zip
When catching an OSError, handle it as an object instead of a tuple (#497374).
Diffstat (limited to 'storage/__init__.py')
-rw-r--r--storage/__init__.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/storage/__init__.py b/storage/__init__.py
index 5b6e0f6e2..e7b53f5b6 100644
--- a/storage/__init__.py
+++ b/storage/__init__.py
@@ -1507,9 +1507,9 @@ class FSSet(object):
try:
device.format.setup(options=options,
chroot=anaconda.rootPath)
- except OSError as (num, msg):
+ except OSError as e:
if intf:
- if num == errno.EEXIST:
+ if e.errno == errno.EEXIST:
intf.messageWindow(_("Invalid mount point"),
_("An error occurred when trying "
"to create %s. Some element of "
@@ -1527,8 +1527,8 @@ class FSSet(object):
"cannot continue.\n\n"
"Press <Enter> to exit the "
"installer.")
- % (device.format.mountpoint, msg))
- log.error("OSError: (%d) %s" % (num, msg) )
+ % (device.format.mountpoint, e.strerror))
+ log.error("OSError: (%d) %s" % (e.errno, e.strerror))
sys.exit(0)
except SystemError as (num, msg):
if raiseErrors: